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

Side by Side Diff: chrome/browser/ui/views/profiles/profile_chooser_view.cc

Issue 2616523004: Layout avatar button
Patch Set: More stuff Created 3 years, 11 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 unified diff | Download patch
« no previous file with comments | « chrome/browser/ui/views/profiles/new_avatar_button.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #include "chrome/browser/ui/views/profiles/profile_chooser_view.h" 5 #include "chrome/browser/ui/views/profiles/profile_chooser_view.h"
6 6
7 #include "base/macros.h" 7 #include "base/macros.h"
8 #include "base/metrics/user_metrics.h" 8 #include "base/metrics/user_metrics.h"
9 #include "base/strings/utf_string_conversions.h" 9 #include "base/strings/utf_string_conversions.h"
10 #include "chrome/browser/browser_process.h" 10 #include "chrome/browser/browser_process.h"
(...skipping 927 matching lines...) Expand 10 before | Expand all | Expand 10 after
938 // closes when it loses focus; however, on Windows, the signin modals do not 938 // closes when it loses focus; however, on Windows, the signin modals do not
939 // take away focus, thus we need to manually close the bubble. 939 // take away focus, thus we need to manually close the bubble.
940 Hide(); 940 Hide();
941 browser_->ShowModalSigninWindow(mode, access_point_); 941 browser_->ShowModalSigninWindow(mode, access_point_);
942 } else { 942 } else {
943 ShowView(mode, avatar_menu_.get()); 943 ShowView(mode, avatar_menu_.get());
944 } 944 }
945 } 945 }
946 946
947 void ProfileChooserView::WindowClosing() { 947 void ProfileChooserView::WindowClosing() {
948
948 DCHECK_EQ(profile_bubble_, this); 949 DCHECK_EQ(profile_bubble_, this);
949 profile_bubble_ = NULL; 950 profile_bubble_ = NULL;
950 951
951 if (tutorial_mode_ == profiles::TUTORIAL_MODE_CONFIRM_SIGNIN) { 952 if (tutorial_mode_ == profiles::TUTORIAL_MODE_CONFIRM_SIGNIN) {
952 LoginUIServiceFactory::GetForProfile(browser_->profile())-> 953 LoginUIServiceFactory::GetForProfile(browser_->profile())->
953 SyncConfirmationUIClosed(LoginUIService::SYNC_WITH_DEFAULT_SETTINGS); 954 SyncConfirmationUIClosed(LoginUIService::SYNC_WITH_DEFAULT_SETTINGS);
954 } 955 }
955 } 956 }
956 957
957 bool ProfileChooserView::AcceleratorPressed( 958 bool ProfileChooserView::AcceleratorPressed(
(...skipping 1346 matching lines...) Expand 10 before | Expand all | Expand 10 after
2304 IncognitoModePrefs::GetAvailability(browser_->profile()->GetPrefs()) != 2305 IncognitoModePrefs::GetAvailability(browser_->profile()->GetPrefs()) !=
2305 IncognitoModePrefs::DISABLED; 2306 IncognitoModePrefs::DISABLED;
2306 return incognito_available && !browser_->profile()->IsGuestSession(); 2307 return incognito_available && !browser_->profile()->IsGuestSession();
2307 } 2308 }
2308 2309
2309 void ProfileChooserView::PostActionPerformed( 2310 void ProfileChooserView::PostActionPerformed(
2310 ProfileMetrics::ProfileDesktopMenu action_performed) { 2311 ProfileMetrics::ProfileDesktopMenu action_performed) {
2311 ProfileMetrics::LogProfileDesktopMenu(action_performed, gaia_service_type_); 2312 ProfileMetrics::LogProfileDesktopMenu(action_performed, gaia_service_type_);
2312 gaia_service_type_ = signin::GAIA_SERVICE_TYPE_NONE; 2313 gaia_service_type_ = signin::GAIA_SERVICE_TYPE_NONE;
2313 } 2314 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/profiles/new_avatar_button.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698