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

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

Issue 2785753003: Exclude building signin view controller and its delegate on ChromeOS (Closed)
Patch Set: Exclude SigninViewController on ChromeOS Created 3 years, 8 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
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/app/vector_icons/vector_icons.h" 10 #include "chrome/app/vector_icons/vector_icons.h"
(...skipping 743 matching lines...) Expand 10 before | Expand all | Expand 10 after
754 if (view_to_focus) 754 if (view_to_focus)
755 view_to_focus->RequestFocus(); 755 view_to_focus->RequestFocus();
756 } 756 }
757 757
758 void ProfileChooserView::ShowViewFromMode(profiles::BubbleViewMode mode) { 758 void ProfileChooserView::ShowViewFromMode(profiles::BubbleViewMode mode) {
759 if (SigninViewController::ShouldShowModalSigninForMode(mode)) { 759 if (SigninViewController::ShouldShowModalSigninForMode(mode)) {
760 // Hides the user menu if it is currently shown. The user menu automatically 760 // Hides the user menu if it is currently shown. The user menu automatically
761 // closes when it loses focus; however, on Windows, the signin modals do not 761 // closes when it loses focus; however, on Windows, the signin modals do not
762 // take away focus, thus we need to manually close the bubble. 762 // take away focus, thus we need to manually close the bubble.
763 Hide(); 763 Hide();
764 browser_->ShowModalSigninWindow(mode, access_point_); 764 browser_->signin_view_controller()->ShowModalSignin(mode, browser_,
765 access_point_);
765 } else { 766 } else {
766 ShowView(mode, avatar_menu_.get()); 767 ShowView(mode, avatar_menu_.get());
767 } 768 }
768 } 769 }
769 770
770 void ProfileChooserView::FocusFirstProfileButton() { 771 void ProfileChooserView::FocusFirstProfileButton() {
771 if (first_profile_button_) 772 if (first_profile_button_)
772 first_profile_button_->RequestFocus(); 773 first_profile_button_->RequestFocus();
773 } 774 }
774 775
(...skipping 1116 matching lines...) Expand 10 before | Expand all | Expand 10 after
1891 IncognitoModePrefs::GetAvailability(browser_->profile()->GetPrefs()) != 1892 IncognitoModePrefs::GetAvailability(browser_->profile()->GetPrefs()) !=
1892 IncognitoModePrefs::DISABLED; 1893 IncognitoModePrefs::DISABLED;
1893 return incognito_available && !browser_->profile()->IsGuestSession(); 1894 return incognito_available && !browser_->profile()->IsGuestSession();
1894 } 1895 }
1895 1896
1896 void ProfileChooserView::PostActionPerformed( 1897 void ProfileChooserView::PostActionPerformed(
1897 ProfileMetrics::ProfileDesktopMenu action_performed) { 1898 ProfileMetrics::ProfileDesktopMenu action_performed) {
1898 ProfileMetrics::LogProfileDesktopMenu(action_performed, gaia_service_type_); 1899 ProfileMetrics::LogProfileDesktopMenu(action_performed, gaia_service_type_);
1899 gaia_service_type_ = signin::GAIA_SERVICE_TYPE_NONE; 1900 gaia_service_type_ = signin::GAIA_SERVICE_TYPE_NONE;
1900 } 1901 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/frame/browser_view.cc ('k') | chrome/browser/ui/webui/signin/inline_login_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698