| OLD | NEW |
| 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/signin_screen_handler.h" | 5 #include "chrome/browser/ui/webui/chromeos/login/signin_screen_handler.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 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 837 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 848 core_oobe_actor_->ShowPasswordChangedScreen(show_password_error); | 848 core_oobe_actor_->ShowPasswordChangedScreen(show_password_error); |
| 849 } | 849 } |
| 850 | 850 |
| 851 void SigninScreenHandler::ShowSigninScreenForCreds( | 851 void SigninScreenHandler::ShowSigninScreenForCreds( |
| 852 const std::string& username, | 852 const std::string& username, |
| 853 const std::string& password) { | 853 const std::string& password) { |
| 854 DCHECK(gaia_screen_handler_); | 854 DCHECK(gaia_screen_handler_); |
| 855 gaia_screen_handler_->ShowSigninScreenForCreds(username, password); | 855 gaia_screen_handler_->ShowSigninScreenForCreds(username, password); |
| 856 } | 856 } |
| 857 | 857 |
| 858 void SigninScreenHandler::SetPublicSessionDisplayName( |
| 859 const std::string& user_id, |
| 860 const std::string& display_name) { |
| 861 CallJS("login.AccountPickerScreen.setPublicSessionDisplayName", |
| 862 user_id, |
| 863 display_name); |
| 864 } |
| 865 |
| 858 void SigninScreenHandler::Observe(int type, | 866 void SigninScreenHandler::Observe(int type, |
| 859 const content::NotificationSource& source, | 867 const content::NotificationSource& source, |
| 860 const content::NotificationDetails& details) { | 868 const content::NotificationDetails& details) { |
| 861 switch (type) { | 869 switch (type) { |
| 862 case chrome::NOTIFICATION_AUTH_NEEDED: { | 870 case chrome::NOTIFICATION_AUTH_NEEDED: { |
| 863 has_pending_auth_ui_ = true; | 871 has_pending_auth_ui_ = true; |
| 864 break; | 872 break; |
| 865 } | 873 } |
| 866 case chrome::NOTIFICATION_AUTH_SUPPLIED: | 874 case chrome::NOTIFICATION_AUTH_SUPPLIED: |
| 867 has_pending_auth_ui_ = false; | 875 has_pending_auth_ui_ = false; |
| (...skipping 572 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1440 return gaia_screen_handler_->frame_error(); | 1448 return gaia_screen_handler_->frame_error(); |
| 1441 } | 1449 } |
| 1442 | 1450 |
| 1443 void SigninScreenHandler::OnCapsLockChanged(bool enabled) { | 1451 void SigninScreenHandler::OnCapsLockChanged(bool enabled) { |
| 1444 caps_lock_enabled_ = enabled; | 1452 caps_lock_enabled_ = enabled; |
| 1445 if (page_is_ready()) | 1453 if (page_is_ready()) |
| 1446 CallJS("login.AccountPickerScreen.setCapsLockState", caps_lock_enabled_); | 1454 CallJS("login.AccountPickerScreen.setCapsLockState", caps_lock_enabled_); |
| 1447 } | 1455 } |
| 1448 | 1456 |
| 1449 } // namespace chromeos | 1457 } // namespace chromeos |
| OLD | NEW |