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