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

Side by Side Diff: chrome/browser/ui/webui/chromeos/login/terms_of_service_screen_handler.cc

Issue 1055863002: ChromeOS: switch UI language before apps are loaded. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove empty line. Created 5 years, 7 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 (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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/webui/chromeos/login/terms_of_service_screen_handler .h" 5 #include "chrome/browser/ui/webui/chromeos/login/terms_of_service_screen_handler .h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/bind_helpers.h" 10 #include "base/bind_helpers.h"
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after
98 return; 98 return;
99 } 99 }
100 100
101 // Switch to the user's UI locale before showing the screen. 101 // Switch to the user's UI locale before showing the screen.
102 locale_util::SwitchLanguageCallback callback( 102 locale_util::SwitchLanguageCallback callback(
103 base::Bind(&TermsOfServiceScreenHandler::OnLanguageChangedCallback, 103 base::Bind(&TermsOfServiceScreenHandler::OnLanguageChangedCallback,
104 base::Unretained(this))); 104 base::Unretained(this)));
105 locale_util::SwitchLanguage(locale, 105 locale_util::SwitchLanguage(locale,
106 true, // enable_locale_keyboard_layouts 106 true, // enable_locale_keyboard_layouts
107 false, // login_layouts_only 107 false, // login_layouts_only
108 callback); 108 callback, ProfileManager::GetActiveUserProfile());
109 } 109 }
110 110
111 void TermsOfServiceScreenHandler::Hide() { 111 void TermsOfServiceScreenHandler::Hide() {
112 } 112 }
113 113
114 void TermsOfServiceScreenHandler::SetDomain(const std::string& domain) { 114 void TermsOfServiceScreenHandler::SetDomain(const std::string& domain) {
115 domain_ = domain; 115 domain_ = domain;
116 UpdateDomainInUI(); 116 UpdateDomainInUI();
117 } 117 }
118 118
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
210 // and continue" button should not be accessible. If the user managed to 210 // and continue" button should not be accessible. If the user managed to
211 // activate it somehow anway, do not treat this as acceptance of the Terms 211 // activate it somehow anway, do not treat this as acceptance of the Terms
212 // and Conditions and end the session instead, as if the user had declined. 212 // and Conditions and end the session instead, as if the user had declined.
213 if (terms_of_service_.empty()) 213 if (terms_of_service_.empty())
214 screen_->OnDecline(); 214 screen_->OnDecline();
215 else 215 else
216 screen_->OnAccept(); 216 screen_->OnAccept();
217 } 217 }
218 218
219 } // namespace chromeos 219 } // namespace chromeos
OLDNEW
« no previous file with comments | « chrome/browser/ui/ash/system_tray_delegate_chromeos.cc ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698