Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_USER_MANAGER_IMPL_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_USER_MANAGER_IMPL_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_USER_MANAGER_IMPL_H_ | 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_USER_MANAGER_IMPL_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 178 | 178 |
| 179 // Returns the user with the given email address if found in the persistent | 179 // Returns the user with the given email address if found in the persistent |
| 180 // list or currently logged in as ephemeral. Returns |NULL| otherwise. | 180 // list or currently logged in as ephemeral. Returns |NULL| otherwise. |
| 181 // Same as FindUser but returns non-const pointer to User object. | 181 // Same as FindUser but returns non-const pointer to User object. |
| 182 User* FindUserAndModify(const std::string& user_id); | 182 User* FindUserAndModify(const std::string& user_id); |
| 183 | 183 |
| 184 // Returns the user with the given email address if found in the persistent | 184 // Returns the user with the given email address if found in the persistent |
| 185 // list. Returns |NULL| otherwise. | 185 // list. Returns |NULL| otherwise. |
| 186 const User* FindUserInList(const std::string& user_id) const; | 186 const User* FindUserInList(const std::string& user_id) const; |
| 187 | 187 |
| 188 // Returns |true| if user with the given id is found in the persistent list. | |
| 189 // Returns |false| otherwise. Does not trigger user loading. | |
|
Nikita (slow)
2013/11/13 01:37:19
nit: drop double space.
Denis Kuznetsov (DE-MUC)
2013/11/14 01:18:17
Done.
Nikita (slow)
2013/11/14 01:19:12
Still an issue.
| |
| 190 const bool UserExistsInList(const std::string& user_id) const; | |
| 191 | |
| 188 // Same as FindUserInList but returns non-const pointer to User object. | 192 // Same as FindUserInList but returns non-const pointer to User object. |
| 189 User* FindUserInListAndModify(const std::string& user_id); | 193 User* FindUserInListAndModify(const std::string& user_id); |
| 190 | 194 |
| 191 // Indicates that a user just logged in as guest. | 195 // Indicates that a user just logged in as guest. |
| 192 void GuestUserLoggedIn(); | 196 void GuestUserLoggedIn(); |
| 193 | 197 |
| 194 // Indicates that a regular user just logged in. | 198 // Indicates that a regular user just logged in. |
| 195 void RegularUserLoggedIn(const std::string& user_id); | 199 void RegularUserLoggedIn(const std::string& user_id); |
| 196 | 200 |
| 197 // Indicates that a regular user just logged in as ephemeral. | 201 // Indicates that a regular user just logged in as ephemeral. |
| (...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 309 const std::string& user_id, | 313 const std::string& user_id, |
| 310 const string16& display_name, | 314 const string16& display_name, |
| 311 const std::string* resolved_account_locale); | 315 const std::string* resolved_account_locale); |
| 312 | 316 |
| 313 // Decorator to the previous function. | 317 // Decorator to the previous function. |
| 314 void UpdateUserAccountDataImplCallbackDecorator( | 318 void UpdateUserAccountDataImplCallbackDecorator( |
| 315 const scoped_ptr<UpdateUserAccountDataCallbackData>& data); | 319 const scoped_ptr<UpdateUserAccountDataCallbackData>& data); |
| 316 | 320 |
| 317 Profile* GetProfileByUser(const User* user) const; | 321 Profile* GetProfileByUser(const User* user) const; |
| 318 | 322 |
| 323 // Implementation for RemoveUser method. This is an asynchronous part of the | |
| 324 // method, that verifies that owner will not get deleted. | |
| 325 void RemoveUserInternal(const std::string& user_email, | |
| 326 RemoveUserDelegate* delegate); | |
| 327 // Implementation for RemoveUser method. This is a synchronous part of the | |
|
Nikita (slow)
2013/11/13 01:27:54
nit: empty line
Denis Kuznetsov (DE-MUC)
2013/11/14 01:18:17
Done.
| |
| 328 // method. | |
|
Nikita (slow)
2013/11/13 01:50:39
Please expand comment and add how this is differen
Nikita (slow)
2013/11/14 01:19:12
Please update comment.
| |
| 329 void RemoveNonOwnerUserInternal(const std::string& user_email, | |
|
Nikita (slow)
2013/11/13 01:37:19
I think you should fix code that calls RemoveUserI
Nikita (slow)
2013/11/13 01:50:39
As discussed offline, my comments regarding moving
Denis Kuznetsov (DE-MUC)
2013/11/14 01:18:17
Done.
| |
| 330 RemoveUserDelegate* delegate); | |
| 331 | |
| 319 // MultiProfileUserControllerDelegate implementation: | 332 // MultiProfileUserControllerDelegate implementation: |
| 320 virtual void OnUserNotAllowed() OVERRIDE; | 333 virtual void OnUserNotAllowed() OVERRIDE; |
| 321 | 334 |
| 322 // Interface to the signed settings store. | 335 // Interface to the signed settings store. |
| 323 CrosSettings* cros_settings_; | 336 CrosSettings* cros_settings_; |
| 324 | 337 |
| 325 // Interface to device-local account definitions and associated policy. | 338 // Interface to device-local account definitions and associated policy. |
| 326 policy::DeviceLocalAccountPolicyService* device_local_account_policy_service_; | 339 policy::DeviceLocalAccountPolicyService* device_local_account_policy_service_; |
| 327 | 340 |
| 328 // True if users have been loaded from prefs already. | 341 // True if users have been loaded from prefs already. |
| (...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 432 scoped_ptr<MultiProfileUserController> multi_profile_user_controller_; | 445 scoped_ptr<MultiProfileUserController> multi_profile_user_controller_; |
| 433 scoped_ptr<MultiProfileFirstRunNotification> | 446 scoped_ptr<MultiProfileFirstRunNotification> |
| 434 multi_profile_first_run_notification_; | 447 multi_profile_first_run_notification_; |
| 435 | 448 |
| 436 DISALLOW_COPY_AND_ASSIGN(UserManagerImpl); | 449 DISALLOW_COPY_AND_ASSIGN(UserManagerImpl); |
| 437 }; | 450 }; |
| 438 | 451 |
| 439 } // namespace chromeos | 452 } // namespace chromeos |
| 440 | 453 |
| 441 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_USER_MANAGER_IMPL_H_ | 454 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_USER_MANAGER_IMPL_H_ |
| OLD | NEW |