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

Unified Diff: chrome/browser/supervised_user/legacy/supervised_user_registration_utility.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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/supervised_user/legacy/supervised_user_registration_utility.h
diff --git a/chrome/browser/supervised_user/legacy/supervised_user_registration_utility.h b/chrome/browser/supervised_user/legacy/supervised_user_registration_utility.h
index 561a8bde1bdee2aed3662e2d586898f5d5e523ff..75709982daf293f19603aa364569840d06cfb0d5 100644
--- a/chrome/browser/supervised_user/legacy/supervised_user_registration_utility.h
+++ b/chrome/browser/supervised_user/legacy/supervised_user_registration_utility.h
@@ -31,6 +31,10 @@ namespace browser_sync {
class DeviceInfo;
}
+namespace user_manager {
+class UserID;
+}
+
// Structure to store registration information.
struct SupervisedUserRegistrationInfo {
SupervisedUserRegistrationInfo(const base::string16& name, int avatar_index);
@@ -62,7 +66,7 @@ class SupervisedUserRegistrationUtility {
// Creates SupervisedUserRegistrationUtility for a given |profile|.
static scoped_ptr<SupervisedUserRegistrationUtility> Create(Profile* profile);
- static std::string GenerateNewSupervisedUserId();
+ static user_manager::UserID GenerateNewSupervisedUserId();
// Registers a new supervised user with the server. |supervised_user_id| is a
// new unique ID for the new supervised user. If its value is the same as that
@@ -72,7 +76,7 @@ class SupervisedUserRegistrationUtility {
// the user and his avatar. |callback| is called with the result of the
// registration. We use the info here and not the profile, because on Chrome
// OS the profile of the supervised user does not yet exist.
- virtual void Register(const std::string& supervised_user_id,
+ virtual void Register(const user_manager::UserID& supervised_user_id,
const SupervisedUserRegistrationInfo& info,
const RegistrationCallback& callback) = 0;

Powered by Google App Engine
This is Rietveld 408576698