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 #include "chrome/browser/chromeos/login/ui/webui_login_display.h" | 5 #include "chrome/browser/chromeos/login/ui/webui_login_display.h" |
6 | 6 |
7 #include "chrome/browser/chromeos/accessibility/accessibility_manager.h" | 7 #include "chrome/browser/chromeos/accessibility/accessibility_manager.h" |
8 #include "chrome/browser/chromeos/login/lock/screen_locker.h" | 8 #include "chrome/browser/chromeos/login/lock/screen_locker.h" |
9 #include "chrome/browser/chromeos/login/screens/chrome_user_selection_screen.h" | 9 #include "chrome/browser/chromeos/login/screens/chrome_user_selection_screen.h" |
10 #include "chrome/browser/chromeos/login/signin_screen_controller.h" | 10 #include "chrome/browser/chromeos/login/signin_screen_controller.h" |
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
122 default: | 122 default: |
123 error_text = l10n_util::GetStringUTF8(error_msg_id); | 123 error_text = l10n_util::GetStringUTF8(error_msg_id); |
124 break; | 124 break; |
125 } | 125 } |
126 | 126 |
127 // Only display hints about keyboard layout if the error is authentication- | 127 // Only display hints about keyboard layout if the error is authentication- |
128 // related. | 128 // related. |
129 if (error_msg_id != IDS_LOGIN_ERROR_WHITELIST && | 129 if (error_msg_id != IDS_LOGIN_ERROR_WHITELIST && |
130 error_msg_id != IDS_ENTERPRISE_LOGIN_ERROR_WHITELIST && | 130 error_msg_id != IDS_ENTERPRISE_LOGIN_ERROR_WHITELIST && |
131 error_msg_id != IDS_LOGIN_ERROR_OWNER_KEY_LOST && | 131 error_msg_id != IDS_LOGIN_ERROR_OWNER_KEY_LOST && |
132 error_msg_id != IDS_LOGIN_ERROR_OWNER_REQUIRED) { | 132 error_msg_id != IDS_LOGIN_ERROR_OWNER_REQUIRED && |
| 133 error_msg_id != IDS_LOGIN_ERROR_GOOGLE_ACCOUNT_NOT_ALLOWED) { |
133 // Display a warning if Caps Lock is on. | 134 // Display a warning if Caps Lock is on. |
134 input_method::InputMethodManager* ime_manager = | 135 input_method::InputMethodManager* ime_manager = |
135 input_method::InputMethodManager::Get(); | 136 input_method::InputMethodManager::Get(); |
136 if (ime_manager->GetImeKeyboard()->CapsLockIsEnabled()) { | 137 if (ime_manager->GetImeKeyboard()->CapsLockIsEnabled()) { |
137 // TODO(ivankr): use a format string instead of concatenation. | 138 // TODO(ivankr): use a format string instead of concatenation. |
138 error_text += "\n" + | 139 error_text += "\n" + |
139 l10n_util::GetStringUTF8(IDS_LOGIN_ERROR_CAPS_LOCK_HINT); | 140 l10n_util::GetStringUTF8(IDS_LOGIN_ERROR_CAPS_LOCK_HINT); |
140 } | 141 } |
141 | 142 |
142 // Display a hint to switch keyboards if there are other active input | 143 // Display a hint to switch keyboards if there are other active input |
(...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
343 } | 344 } |
344 | 345 |
345 bool WebUILoginDisplay::IsUserWhitelisted(const AccountId& account_id) { | 346 bool WebUILoginDisplay::IsUserWhitelisted(const AccountId& account_id) { |
346 DCHECK(delegate_); | 347 DCHECK(delegate_); |
347 if (delegate_) | 348 if (delegate_) |
348 return delegate_->IsUserWhitelisted(account_id); | 349 return delegate_->IsUserWhitelisted(account_id); |
349 return true; | 350 return true; |
350 } | 351 } |
351 | 352 |
352 } // namespace chromeos | 353 } // namespace chromeos |
OLD | NEW |