Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(8064)

Unified Diff: chrome/browser/ui/cocoa/profiles/profile_chooser_controller.mm

Issue 2920853004: [sync] Display an error when sync settings aren't confirmed (Closed)
Patch Set: Reformat, remove browser_options change Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/cocoa/profiles/profile_chooser_controller.mm
diff --git a/chrome/browser/ui/cocoa/profiles/profile_chooser_controller.mm b/chrome/browser/ui/cocoa/profiles/profile_chooser_controller.mm
index 91dabc8e0050c4ef142e9e5feab18e3cc3b3fb5f..e0b3378407c457eac4750243455cb4b9fd8f4df1 100644
--- a/chrome/browser/ui/cocoa/profiles/profile_chooser_controller.mm
+++ b/chrome/browser/ui/cocoa/profiles/profile_chooser_controller.mm
@@ -891,7 +891,7 @@ class ActiveProfileObserverBridge : public AvatarMenuObserver,
chrome::OpenUpdateChromeDialog(browser_);
}
-- (IBAction)showSyncPassphraseSetupView:(id)sender {
+- (IBAction)showSyncSetupView:(id)sender {
chrome::ShowSettingsSubPage(browser_, chrome::kSyncSetupSubPage);
}
@@ -1207,9 +1207,12 @@ class ActiveProfileObserverBridge : public AvatarMenuObserver,
- (NSView*)buildSyncErrorViewIfNeeded {
int contentStringId, buttonStringId;
SEL buttonAction;
+ SigninManagerBase* signinManager =
+ SigninManagerFactory::GetForProfile(browser_->profile());
sync_ui_util::AvatarSyncErrorType error =
sync_ui_util::GetMessagesForAvatarSyncError(
- browser_->profile(), &contentStringId, &buttonStringId);
+ browser_->profile(), *signinManager, &contentStringId,
+ &buttonStringId);
switch (error) {
case sync_ui_util::MANAGED_USER_UNRECOVERABLE_ERROR:
buttonAction = @selector(showSignoutView:);
@@ -1227,7 +1230,8 @@ class ActiveProfileObserverBridge : public AvatarMenuObserver,
buttonAction = @selector(showUpdateChromeView:);
break;
case sync_ui_util::PASSPHRASE_ERROR:
- buttonAction = @selector(showSyncPassphraseSetupView:);
+ case sync_ui_util::SETTINGS_UNCONFIRMED_ERROR:
+ buttonAction = @selector(showSyncSetupView:);
break;
case sync_ui_util::NO_SYNC_ERROR:
return nil;

Powered by Google App Engine
This is Rietveld 408576698