OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #import "chrome/browser/ui/cocoa/profiles/profile_chooser_controller.h" | 5 #import "chrome/browser/ui/cocoa/profiles/profile_chooser_controller.h" |
6 | 6 |
7 #import <Carbon/Carbon.h> // kVK_Return. | 7 #import <Carbon/Carbon.h> // kVK_Return. |
8 #import <Cocoa/Cocoa.h> | 8 #import <Cocoa/Cocoa.h> |
9 | 9 |
10 #include "base/mac/bundle_locations.h" | 10 #include "base/mac/bundle_locations.h" |
(...skipping 1103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1114 - (IBAction)showLearnMorePage:(id)sender { | 1114 - (IBAction)showLearnMorePage:(id)sender { |
1115 signin_ui_util::ShowSigninErrorLearnMorePage(browser_->profile()); | 1115 signin_ui_util::ShowSigninErrorLearnMorePage(browser_->profile()); |
1116 } | 1116 } |
1117 | 1117 |
1118 - (IBAction)configureSyncSettings:(id)sender { | 1118 - (IBAction)configureSyncSettings:(id)sender { |
1119 tutorialMode_ = profiles::TUTORIAL_MODE_NONE; | 1119 tutorialMode_ = profiles::TUTORIAL_MODE_NONE; |
1120 LoginUIServiceFactory::GetForProfile(browser_->profile())-> | 1120 LoginUIServiceFactory::GetForProfile(browser_->profile())-> |
1121 SyncConfirmationUIClosed(true); | 1121 SyncConfirmationUIClosed(true); |
1122 ProfileMetrics::LogProfileNewAvatarMenuSignin( | 1122 ProfileMetrics::LogProfileNewAvatarMenuSignin( |
1123 ProfileMetrics::PROFILE_AVATAR_MENU_SIGNIN_SETTINGS); | 1123 ProfileMetrics::PROFILE_AVATAR_MENU_SIGNIN_SETTINGS); |
| 1124 [self close]; |
1124 } | 1125 } |
1125 | 1126 |
1126 - (IBAction)syncSettingsConfirmed:(id)sender { | 1127 - (IBAction)syncSettingsConfirmed:(id)sender { |
1127 tutorialMode_ = profiles::TUTORIAL_MODE_NONE; | 1128 tutorialMode_ = profiles::TUTORIAL_MODE_NONE; |
1128 LoginUIServiceFactory::GetForProfile(browser_->profile())-> | 1129 LoginUIServiceFactory::GetForProfile(browser_->profile())-> |
1129 SyncConfirmationUIClosed(false); | 1130 SyncConfirmationUIClosed(false); |
1130 ProfileMetrics::LogProfileNewAvatarMenuSignin( | 1131 ProfileMetrics::LogProfileNewAvatarMenuSignin( |
1131 ProfileMetrics::PROFILE_AVATAR_MENU_SIGNIN_OK); | 1132 ProfileMetrics::PROFILE_AVATAR_MENU_SIGNIN_OK); |
1132 [self initMenuContentsWithView:profiles::BUBBLE_VIEW_MODE_PROFILE_CHOOSER]; | 1133 [self initMenuContentsWithView:profiles::BUBBLE_VIEW_MODE_PROFILE_CHOOSER]; |
1133 } | 1134 } |
(...skipping 1265 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2399 } | 2400 } |
2400 | 2401 |
2401 - (bool)shouldShowGoIncognito { | 2402 - (bool)shouldShowGoIncognito { |
2402 bool incognitoAvailable = | 2403 bool incognitoAvailable = |
2403 IncognitoModePrefs::GetAvailability(browser_->profile()->GetPrefs()) != | 2404 IncognitoModePrefs::GetAvailability(browser_->profile()->GetPrefs()) != |
2404 IncognitoModePrefs::DISABLED; | 2405 IncognitoModePrefs::DISABLED; |
2405 return incognitoAvailable && !browser_->profile()->IsGuestSession(); | 2406 return incognitoAvailable && !browser_->profile()->IsGuestSession(); |
2406 } | 2407 } |
2407 | 2408 |
2408 @end | 2409 @end |
OLD | NEW |