| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 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_GAIA_SCREEN_HANDLER_H_ | 5 #ifndef CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_GAIA_SCREEN_HANDLER_H_ |
| 6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_GAIA_SCREEN_HANDLER_H_ | 6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_GAIA_SCREEN_HANDLER_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 46 | 46 |
| 47 // True if user list is non-empty. | 47 // True if user list is non-empty. |
| 48 bool has_users; | 48 bool has_users; |
| 49 | 49 |
| 50 // Email of the current user. | 50 // Email of the current user. |
| 51 std::string email; | 51 std::string email; |
| 52 | 52 |
| 53 // GAIA ID of the current user. | 53 // GAIA ID of the current user. |
| 54 std::string gaia_id; | 54 std::string gaia_id; |
| 55 | 55 |
| 56 // GAPS cookie. |
| 57 std::string gaps_cookie; |
| 58 |
| 56 // Whether consumer management enrollment is in progress. | 59 // Whether consumer management enrollment is in progress. |
| 57 bool is_enrolling_consumer_management; | 60 bool is_enrolling_consumer_management; |
| 58 }; | 61 }; |
| 59 | 62 |
| 60 // A class that handles WebUI hooks in Gaia screen. | 63 // A class that handles WebUI hooks in Gaia screen. |
| 61 class GaiaScreenHandler : public BaseScreenHandler { | 64 class GaiaScreenHandler : public BaseScreenHandler { |
| 62 public: | 65 public: |
| 63 enum FrameState { | 66 enum FrameState { |
| 64 FRAME_STATE_UNKNOWN = 0, | 67 FRAME_STATE_UNKNOWN = 0, |
| 65 FRAME_STATE_LOADING, | 68 FRAME_STATE_LOADING, |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 108 // WebUIMessageHandler implementation: | 111 // WebUIMessageHandler implementation: |
| 109 void RegisterMessages() override; | 112 void RegisterMessages() override; |
| 110 | 113 |
| 111 // WebUI message handlers. | 114 // WebUI message handlers. |
| 112 void HandleFrameLoadingCompleted(int status); | 115 void HandleFrameLoadingCompleted(int status); |
| 113 void HandleWebviewLoadAborted(const std::string& error_reason_str); | 116 void HandleWebviewLoadAborted(const std::string& error_reason_str); |
| 114 void HandleCompleteAuthentication(const std::string& gaia_id, | 117 void HandleCompleteAuthentication(const std::string& gaia_id, |
| 115 const std::string& email, | 118 const std::string& email, |
| 116 const std::string& password, | 119 const std::string& password, |
| 117 const std::string& auth_code, | 120 const std::string& auth_code, |
| 118 bool using_saml); | 121 bool using_saml, |
| 122 const std::string& gaps_cookie); |
| 119 void HandleCompleteAuthenticationAuthCodeOnly(const std::string& auth_code); | 123 void HandleCompleteAuthenticationAuthCodeOnly(const std::string& auth_code); |
| 120 void HandleCompleteLogin(const std::string& gaia_id, | 124 void HandleCompleteLogin(const std::string& gaia_id, |
| 121 const std::string& typed_email, | 125 const std::string& typed_email, |
| 122 const std::string& password, | 126 const std::string& password, |
| 123 bool using_saml); | 127 bool using_saml); |
| 124 | 128 |
| 125 void HandleUsingSAMLAPI(); | 129 void HandleUsingSAMLAPI(); |
| 126 void HandleScrapedPasswordCount(int password_count); | 130 void HandleScrapedPasswordCount(int password_count); |
| 127 void HandleScrapedPasswordVerificationFailed(); | 131 void HandleScrapedPasswordVerificationFailed(); |
| 128 | 132 |
| (...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 269 scoped_ptr<ScopedGaiaAuthExtension> auth_extension_; | 273 scoped_ptr<ScopedGaiaAuthExtension> auth_extension_; |
| 270 | 274 |
| 271 base::WeakPtrFactory<GaiaScreenHandler> weak_factory_; | 275 base::WeakPtrFactory<GaiaScreenHandler> weak_factory_; |
| 272 | 276 |
| 273 DISALLOW_COPY_AND_ASSIGN(GaiaScreenHandler); | 277 DISALLOW_COPY_AND_ASSIGN(GaiaScreenHandler); |
| 274 }; | 278 }; |
| 275 | 279 |
| 276 } // namespace chromeos | 280 } // namespace chromeos |
| 277 | 281 |
| 278 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_GAIA_SCREEN_HANDLER_H_ | 282 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_GAIA_SCREEN_HANDLER_H_ |
| OLD | NEW |