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 <map> | 8 #include <map> |
9 #include <memory> | 9 #include <memory> |
10 #include <set> | 10 #include <set> |
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
90 HelpAppLauncher::HelpTopic help_topic_id) = 0; | 90 HelpAppLauncher::HelpTopic help_topic_id) = 0; |
91 virtual void ShowErrorScreen(LoginDisplay::SigninError error_id) = 0; | 91 virtual void ShowErrorScreen(LoginDisplay::SigninError error_id) = 0; |
92 virtual void ShowSigninUI(const std::string& email) = 0; | 92 virtual void ShowSigninUI(const std::string& email) = 0; |
93 virtual void ShowPasswordChangedDialog(bool show_password_error, | 93 virtual void ShowPasswordChangedDialog(bool show_password_error, |
94 const std::string& email) = 0; | 94 const std::string& email) = 0; |
95 // Show sign-in screen for the given credentials. | 95 // Show sign-in screen for the given credentials. |
96 virtual void ShowSigninScreenForCreds(const std::string& username, | 96 virtual void ShowSigninScreenForCreds(const std::string& username, |
97 const std::string& password) = 0; | 97 const std::string& password) = 0; |
98 virtual void ShowWhitelistCheckFailedError() = 0; | 98 virtual void ShowWhitelistCheckFailedError() = 0; |
99 virtual void ShowUnrecoverableCrypthomeErrorDialog() = 0; | 99 virtual void ShowUnrecoverableCrypthomeErrorDialog() = 0; |
100 virtual void LoadUsers(const base::ListValue& users_list, | 100 virtual void LoadUsers(const user_manager::UserList& users, |
101 bool show_guest) = 0; | 101 const base::ListValue& users_list) = 0; |
| 102 |
102 protected: | 103 protected: |
103 virtual ~LoginDisplayWebUIHandler() {} | 104 virtual ~LoginDisplayWebUIHandler() {} |
104 }; | 105 }; |
105 | 106 |
106 // An interface for SigninScreenHandler to call WebUILoginDisplay. | 107 // An interface for SigninScreenHandler to call WebUILoginDisplay. |
107 class SigninScreenHandlerDelegate { | 108 class SigninScreenHandlerDelegate { |
108 public: | 109 public: |
109 // --------------- Password change flow methods. | 110 // --------------- Password change flow methods. |
110 // Cancels current password changed flow. | 111 // Cancels current password changed flow. |
111 virtual void CancelPasswordChangedFlow() = 0; | 112 virtual void CancelPasswordChangedFlow() = 0; |
(...skipping 210 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
322 const std::string& help_link_text, | 323 const std::string& help_link_text, |
323 HelpAppLauncher::HelpTopic help_topic_id) override; | 324 HelpAppLauncher::HelpTopic help_topic_id) override; |
324 void ShowSigninUI(const std::string& email) override; | 325 void ShowSigninUI(const std::string& email) override; |
325 void ShowPasswordChangedDialog(bool show_password_error, | 326 void ShowPasswordChangedDialog(bool show_password_error, |
326 const std::string& email) override; | 327 const std::string& email) override; |
327 void ShowErrorScreen(LoginDisplay::SigninError error_id) override; | 328 void ShowErrorScreen(LoginDisplay::SigninError error_id) override; |
328 void ShowSigninScreenForCreds(const std::string& username, | 329 void ShowSigninScreenForCreds(const std::string& username, |
329 const std::string& password) override; | 330 const std::string& password) override; |
330 void ShowWhitelistCheckFailedError() override; | 331 void ShowWhitelistCheckFailedError() override; |
331 void ShowUnrecoverableCrypthomeErrorDialog() override; | 332 void ShowUnrecoverableCrypthomeErrorDialog() override; |
332 void LoadUsers(const base::ListValue& users_list, bool show_guest) override; | 333 void LoadUsers(const user_manager::UserList& users, |
| 334 const base::ListValue& users_list) override; |
333 | 335 |
334 // content::NotificationObserver implementation: | 336 // content::NotificationObserver implementation: |
335 void Observe(int type, | 337 void Observe(int type, |
336 const content::NotificationSource& source, | 338 const content::NotificationSource& source, |
337 const content::NotificationDetails& details) override; | 339 const content::NotificationDetails& details) override; |
338 | 340 |
339 // PowerManagerClient::Observer implementation: | 341 // PowerManagerClient::Observer implementation: |
340 void SuspendDone(const base::TimeDelta& sleep_duration) override; | 342 void SuspendDone(const base::TimeDelta& sleep_duration) override; |
341 | 343 |
342 // ash::mojom::TouchView: | 344 // ash::mojom::TouchView: |
(...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
535 std::unique_ptr<AccountId> focused_pod_account_id_; | 537 std::unique_ptr<AccountId> focused_pod_account_id_; |
536 | 538 |
537 base::WeakPtrFactory<SigninScreenHandler> weak_factory_; | 539 base::WeakPtrFactory<SigninScreenHandler> weak_factory_; |
538 | 540 |
539 DISALLOW_COPY_AND_ASSIGN(SigninScreenHandler); | 541 DISALLOW_COPY_AND_ASSIGN(SigninScreenHandler); |
540 }; | 542 }; |
541 | 543 |
542 } // namespace chromeos | 544 } // namespace chromeos |
543 | 545 |
544 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_SIGNIN_SCREEN_HANDLER_H_ | 546 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_SIGNIN_SCREEN_HANDLER_H_ |
OLD | NEW |