Commit e1c8b56d authored by Peter K. Lee's avatar Peter K. Lee Committed by Commit Bot

CheckForFirstPartyApps not needed if Mailto is handled by Google UI

Cq-Include-Trybots: luci.chromium.try:ios-simulator-cronet;luci.chromium.try:ios-simulator-full-configs
Change-Id: I0651ad924a0cf050850cc5298b247c44abd355a4
Reviewed-on: https://chromium-review.googlesource.com/c/1287298Reviewed-by: default avatarJustin Cohen <justincohen@chromium.org>
Commit-Queue: Peter Lee <pkl@chromium.org>
Cr-Commit-Position: refs/heads/master@{#600614}
parent 7c2fd410
......@@ -1138,21 +1138,18 @@ enum class ShowTabSwitcherSnapshotResult {
}
- (void)initializeMailtoHandling {
if (base::FeatureList::IsEnabled(kMailtoHandledWithGoogleUI)) {
__weak __typeof(self) weakSelf = self;
[[DeferredInitializationRunner sharedInstance]
enqueueBlockNamed:kMailtoHandlingInitialization
block:^{
__strong __typeof(weakSelf) strongSelf = weakSelf;
if (!strongSelf || !strongSelf->_mainBrowserState) {
return;
}
ios::GetChromeBrowserProvider()
->GetMailtoHandlerProvider()
->PrepareMailtoHandling(
strongSelf->_mainBrowserState);
}];
}
__weak __typeof(self) weakSelf = self;
[[DeferredInitializationRunner sharedInstance]
enqueueBlockNamed:kMailtoHandlingInitialization
block:^{
__strong __typeof(weakSelf) strongSelf = weakSelf;
if (!strongSelf || !strongSelf->_mainBrowserState) {
return;
}
ios::GetChromeBrowserProvider()
->GetMailtoHandlerProvider()
->PrepareMailtoHandling(strongSelf->_mainBrowserState);
}];
}
- (void)startFreeMemoryMonitoring {
......@@ -1178,8 +1175,10 @@ enum class ShowTabSwitcherSnapshotResult {
[self scheduleStartupAttemptReset];
[self startFreeMemoryMonitoring];
[self scheduleAppDistributionPings];
[self scheduleCheckForFirstPartyApps];
[self initializeMailtoHandling];
if (base::FeatureList::IsEnabled(kMailtoHandledWithGoogleUI))
[self initializeMailtoHandling];
else
[self scheduleCheckForFirstPartyApps];
}
- (void)scheduleTasksRequiringBVCWithBrowserState {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment