| 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 #ifndef CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_SIGNIN_SCREEN_HANDLER_H_ | 5 #ifndef CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_SIGNIN_SCREEN_HANDLER_H_ |
| 6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_SIGNIN_SCREEN_HANDLER_H_ | 6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_SIGNIN_SCREEN_HANDLER_H_ |
| 7 | 7 |
| 8 #include <set> | 8 #include <set> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 150 // Whether user sign in has completed. | 150 // Whether user sign in has completed. |
| 151 virtual bool IsUserSigninCompleted() const = 0; | 151 virtual bool IsUserSigninCompleted() const = 0; |
| 152 | 152 |
| 153 // Sets the displayed email for the next login attempt. If it succeeds, | 153 // Sets the displayed email for the next login attempt. If it succeeds, |
| 154 // user's displayed email value will be updated to |email|. | 154 // user's displayed email value will be updated to |email|. |
| 155 virtual void SetDisplayEmail(const std::string& email) = 0; | 155 virtual void SetDisplayEmail(const std::string& email) = 0; |
| 156 | 156 |
| 157 // Signs out if the screen is currently locked. | 157 // Signs out if the screen is currently locked. |
| 158 virtual void Signout() = 0; | 158 virtual void Signout() = 0; |
| 159 | 159 |
| 160 // Login to kiosk mode for app with |app_id|. |
| 161 virtual void LoginAsKioskApp(const std::string& app_id) = 0; |
| 162 |
| 160 protected: | 163 protected: |
| 161 virtual ~SigninScreenHandlerDelegate() {} | 164 virtual ~SigninScreenHandlerDelegate() {} |
| 162 }; | 165 }; |
| 163 | 166 |
| 164 // A class that handles the WebUI hooks in sign-in screen in OobeDisplay | 167 // A class that handles the WebUI hooks in sign-in screen in OobeDisplay |
| 165 // and LoginDisplay. | 168 // and LoginDisplay. |
| 166 class SigninScreenHandler | 169 class SigninScreenHandler |
| 167 : public BaseScreenHandler, | 170 : public BaseScreenHandler, |
| 168 public LoginDisplayWebUIHandler, | 171 public LoginDisplayWebUIHandler, |
| 169 public SystemKeyEventListener::CapsLockObserver, | 172 public SystemKeyEventListener::CapsLockObserver, |
| (...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 320 void HandleMigrateUserData(const std::string& password); | 323 void HandleMigrateUserData(const std::string& password); |
| 321 void HandleResyncUserData(); | 324 void HandleResyncUserData(); |
| 322 void HandleLoginUIStateChanged(const std::string& source, bool new_value); | 325 void HandleLoginUIStateChanged(const std::string& source, bool new_value); |
| 323 void HandleUnlockOnLoginSuccess(); | 326 void HandleUnlockOnLoginSuccess(); |
| 324 void HandleLoginScreenUpdate(); | 327 void HandleLoginScreenUpdate(); |
| 325 void HandleFrameLoadingCompleted(int status); | 328 void HandleFrameLoadingCompleted(int status); |
| 326 void HandleShowLoadingTimeoutError(); | 329 void HandleShowLoadingTimeoutError(); |
| 327 void HandleUpdateOfflineLogin(bool offline_login_active); | 330 void HandleUpdateOfflineLogin(bool offline_login_active); |
| 328 void HandleShowLocallyManagedUserCreationScreen(); | 331 void HandleShowLocallyManagedUserCreationScreen(); |
| 329 void HandleFocusPod(const std::string& user_id); | 332 void HandleFocusPod(const std::string& user_id); |
| 333 void HandleLaunchKioskApp(const std::string& app_id); |
| 330 | 334 |
| 331 // Fills |user_dict| with information about |user|. | 335 // Fills |user_dict| with information about |user|. |
| 332 static void FillUserDictionary(User* user, | 336 static void FillUserDictionary(User* user, |
| 333 bool is_owner, | 337 bool is_owner, |
| 334 DictionaryValue* user_dict); | 338 DictionaryValue* user_dict); |
| 335 | 339 |
| 336 // Sends user list to account picker. | 340 // Sends user list to account picker. |
| 337 void SendUserList(bool animated); | 341 void SendUserList(bool animated); |
| 338 | 342 |
| 339 // Kick off cookie / local storage cleanup. | 343 // Kick off cookie / local storage cleanup. |
| (...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 466 // NOTIFICATION_AUTH_NEEDED and reset on either NOTIFICATION_AUTH_SUPPLIED or | 470 // NOTIFICATION_AUTH_NEEDED and reset on either NOTIFICATION_AUTH_SUPPLIED or |
| 467 // NOTIFICATION_AUTH_CANCELLED. | 471 // NOTIFICATION_AUTH_CANCELLED. |
| 468 bool has_pending_auth_ui_; | 472 bool has_pending_auth_ui_; |
| 469 | 473 |
| 470 DISALLOW_COPY_AND_ASSIGN(SigninScreenHandler); | 474 DISALLOW_COPY_AND_ASSIGN(SigninScreenHandler); |
| 471 }; | 475 }; |
| 472 | 476 |
| 473 } // namespace chromeos | 477 } // namespace chromeos |
| 474 | 478 |
| 475 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_SIGNIN_SCREEN_HANDLER_H_ | 479 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_SIGNIN_SCREEN_HANDLER_H_ |
| OLD | NEW |