Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(58)

Side by Side Diff: chrome/browser/chromeos/login/app_launch_signin_screen.h

Issue 1165323004: We should use UserID object to identify users instead of username. Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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_CHROMEOS_LOGIN_APP_LAUNCH_SIGNIN_SCREEN_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_APP_LAUNCH_SIGNIN_SCREEN_H_
6 #define CHROME_BROWSER_CHROMEOS_LOGIN_APP_LAUNCH_SIGNIN_SCREEN_H_ 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_APP_LAUNCH_SIGNIN_SCREEN_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
11 #include "chrome/browser/ui/webui/chromeos/login/signin_screen_handler.h" 11 #include "chrome/browser/ui/webui/chromeos/login/signin_screen_handler.h"
12 #include "chromeos/login/auth/auth_status_consumer.h" 12 #include "chromeos/login/auth/auth_status_consumer.h"
13 #include "chromeos/login/auth/authenticator.h" 13 #include "chromeos/login/auth/authenticator.h"
14 #include "components/proximity_auth/screenlock_bridge.h" 14 #include "components/proximity_auth/screenlock_bridge.h"
15 #include "components/user_manager/user.h" 15 #include "components/user_manager/user.h"
16 #include "components/user_manager/user_manager.h" 16 #include "components/user_manager/user_manager.h"
17 17
18 namespace user_manager {
19 class UserID;
20 }
21
18 namespace chromeos { 22 namespace chromeos {
19 23
20 class OobeUI; 24 class OobeUI;
21 25
22 // The app launch signin screen shows the user pod of the device owner 26 // The app launch signin screen shows the user pod of the device owner
23 // and requires the user to login in order to access the network dialog. 27 // and requires the user to login in order to access the network dialog.
24 // This screen is quite similar to the standard lock screen, but we do not 28 // This screen is quite similar to the standard lock screen, but we do not
25 // create a new view to superimpose over the desktop. 29 // create a new view to superimpose over the desktop.
26 // 30 //
27 // TODO(tengs): This class doesn't quite follow the idiom of the other 31 // TODO(tengs): This class doesn't quite follow the idiom of the other
(...skipping 22 matching lines...) Expand all
50 user_manager::UserManager* GetUserManager(); 54 user_manager::UserManager* GetUserManager();
51 55
52 // SigninScreenHandlerDelegate implementation: 56 // SigninScreenHandlerDelegate implementation:
53 void CancelPasswordChangedFlow() override; 57 void CancelPasswordChangedFlow() override;
54 void CancelUserAdding() override; 58 void CancelUserAdding() override;
55 void CreateAccount() override; 59 void CreateAccount() override;
56 void CompleteLogin(const UserContext& user_context) override; 60 void CompleteLogin(const UserContext& user_context) override;
57 void Login(const UserContext& user_context, 61 void Login(const UserContext& user_context,
58 const SigninSpecifics& specifics) override; 62 const SigninSpecifics& specifics) override;
59 void MigrateUserData(const std::string& old_password) override; 63 void MigrateUserData(const std::string& old_password) override;
60 void LoadWallpaper(const std::string& username) override; 64 void LoadWallpaper(const user_manager::UserID& user_id) override;
61 void LoadSigninWallpaper() override; 65 void LoadSigninWallpaper() override;
62 void OnSigninScreenReady() override; 66 void OnSigninScreenReady() override;
63 void RemoveUser(const std::string& username) override; 67 void RemoveUser(const user_manager::UserID& user_id) override;
64 void ResyncUserData() override; 68 void ResyncUserData() override;
65 void ShowEnterpriseEnrollmentScreen() override; 69 void ShowEnterpriseEnrollmentScreen() override;
66 void ShowEnableDebuggingScreen() override; 70 void ShowEnableDebuggingScreen() override;
67 void ShowKioskEnableScreen() override; 71 void ShowKioskEnableScreen() override;
68 void ShowKioskAutolaunchScreen() override; 72 void ShowKioskAutolaunchScreen() override;
69 void ShowWrongHWIDScreen() override; 73 void ShowWrongHWIDScreen() override;
70 void SetWebUIHandler(LoginDisplayWebUIHandler* webui_handler) override; 74 void SetWebUIHandler(LoginDisplayWebUIHandler* webui_handler) override;
71 virtual void ShowSigninScreenForCreds(const std::string& username, 75 virtual void ShowSigninScreenForCreds(const user_manager::UserID& user_id,
72 const std::string& password); 76 const std::string& password);
73 const user_manager::UserList& GetUsers() const override; 77 const user_manager::UserList& GetUsers() const override;
74 bool IsShowGuest() const override; 78 bool IsShowGuest() const override;
75 bool IsShowUsers() const override; 79 bool IsShowUsers() const override;
76 bool IsSigninInProgress() const override; 80 bool IsSigninInProgress() const override;
77 bool IsUserSigninCompleted() const override; 81 bool IsUserSigninCompleted() const override;
78 void SetDisplayEmail(const std::string& email) override; 82 void SetDisplayEmail(const std::string& email) override;
79 void Signout() override; 83 void Signout() override;
80 void HandleGetUsers() override; 84 void HandleGetUsers() override;
81 void CheckUserStatus(const std::string& user_id) override; 85 void CheckUserStatus(const user_manager::UserID& user_id) override;
82 86
83 // AuthStatusConsumer implementation: 87 // AuthStatusConsumer implementation:
84 void OnAuthFailure(const AuthFailure& error) override; 88 void OnAuthFailure(const AuthFailure& error) override;
85 void OnAuthSuccess(const UserContext& user_context) override; 89 void OnAuthSuccess(const UserContext& user_context) override;
86 90
87 OobeUI* oobe_ui_; 91 OobeUI* oobe_ui_;
88 Delegate* delegate_; 92 Delegate* delegate_;
89 LoginDisplayWebUIHandler* webui_handler_; 93 LoginDisplayWebUIHandler* webui_handler_;
90 scoped_refptr<Authenticator> authenticator_; 94 scoped_refptr<Authenticator> authenticator_;
91 95
92 // This list should have at most one user, and that user should be the owner. 96 // This list should have at most one user, and that user should be the owner.
93 user_manager::UserList owner_user_list_; 97 user_manager::UserList owner_user_list_;
94 98
95 static user_manager::UserManager* test_user_manager_; 99 static user_manager::UserManager* test_user_manager_;
96 100
97 DISALLOW_COPY_AND_ASSIGN(AppLaunchSigninScreen); 101 DISALLOW_COPY_AND_ASSIGN(AppLaunchSigninScreen);
98 }; 102 };
99 103
100 } // namespace chromeos 104 } // namespace chromeos
101 105
102 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_APP_LAUNCH_SIGNIN_SCREEN_H_ 106 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_APP_LAUNCH_SIGNIN_SCREEN_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698