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 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_EASY_UNLOCK_EASY_UNLOCK_USER_LOGIN_FLOW_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_EASY_UNLOCK_EASY_UNLOCK_USER_LOGIN_FLOW_H_ |
6 #define CHROME_BROWSER_CHROMEOS_LOGIN_EASY_UNLOCK_EASY_UNLOCK_USER_LOGIN_FLOW_H_ | 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_EASY_UNLOCK_EASY_UNLOCK_USER_LOGIN_FLOW_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/macros.h" | 10 #include "base/macros.h" |
11 #include "chrome/browser/chromeos/login/user_flow.h" | 11 #include "chrome/browser/chromeos/login/user_flow.h" |
12 | 12 |
| 13 namespace user_manager { |
| 14 class UserID; |
| 15 } |
| 16 |
13 // Handler for login flow initiazted by Easy Signin login attempt. | 17 // Handler for login flow initiazted by Easy Signin login attempt. |
14 // The only difference to the default login flow is hanlding of the auth | 18 // The only difference to the default login flow is hanlding of the auth |
15 // failure. | 19 // failure. |
16 class EasyUnlockUserLoginFlow : public chromeos::ExtendedUserFlow { | 20 class EasyUnlockUserLoginFlow : public chromeos::ExtendedUserFlow { |
17 public: | 21 public: |
18 explicit EasyUnlockUserLoginFlow(const std::string& user_id); | 22 explicit EasyUnlockUserLoginFlow(const user_manager::UserID& user_id); |
19 ~EasyUnlockUserLoginFlow() override; | 23 ~EasyUnlockUserLoginFlow() override; |
20 | 24 |
21 private: | 25 private: |
22 // chromeos::ExtendedUserFlow implementation. | 26 // chromeos::ExtendedUserFlow implementation. |
23 bool CanLockScreen() override; | 27 bool CanLockScreen() override; |
24 bool ShouldLaunchBrowser() override; | 28 bool ShouldLaunchBrowser() override; |
25 bool ShouldSkipPostLoginScreens() override; | 29 bool ShouldSkipPostLoginScreens() override; |
26 bool HandleLoginFailure(const chromeos::AuthFailure& failure) override; | 30 bool HandleLoginFailure(const chromeos::AuthFailure& failure) override; |
27 void HandleLoginSuccess(const chromeos::UserContext& context) override; | 31 void HandleLoginSuccess(const chromeos::UserContext& context) override; |
28 bool HandlePasswordChangeDetected() override; | 32 bool HandlePasswordChangeDetected() override; |
29 void HandleOAuthTokenStatusChange( | 33 void HandleOAuthTokenStatusChange( |
30 user_manager::User::OAuthTokenStatus status) override; | 34 user_manager::User::OAuthTokenStatus status) override; |
31 void LaunchExtraSteps(Profile* profile) override; | 35 void LaunchExtraSteps(Profile* profile) override; |
32 bool SupportsEarlyRestartToApplyFlags() override; | 36 bool SupportsEarlyRestartToApplyFlags() override; |
33 | 37 |
34 DISALLOW_COPY_AND_ASSIGN(EasyUnlockUserLoginFlow); | 38 DISALLOW_COPY_AND_ASSIGN(EasyUnlockUserLoginFlow); |
35 }; | 39 }; |
36 | 40 |
37 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_EASY_UNLOCK_EASY_UNLOCK_USER_LOGIN_FLOW
_H_ | 41 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_EASY_UNLOCK_EASY_UNLOCK_USER_LOGIN_FLOW
_H_ |
OLD | NEW |