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

Unified Diff: chrome/browser/resources/md_user_manager/profile_browser_proxy.js

Issue 1826903002: updated UI, default profile name, check for existing supervised user before create (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed comments Created 4 years, 8 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/resources/md_user_manager/profile_browser_proxy.js
diff --git a/chrome/browser/resources/md_user_manager/profile_browser_proxy.js b/chrome/browser/resources/md_user_manager/profile_browser_proxy.js
index 165b92f27947ba12ca62b096a6c3cba6ab5bc258..b65f737ab84927fdd8455fbcfc157c041b997c75 100644
--- a/chrome/browser/resources/md_user_manager/profile_browser_proxy.js
+++ b/chrome/browser/resources/md_user_manager/profile_browser_proxy.js
@@ -13,6 +13,13 @@ var SignedInUser;
/** @typedef {{name: string, filePath: string, isSupervised: boolean}} */
var ProfileInfo;
+/** @typedef {{id: string,
+ * name: string,
+ * iconURL: string,
+ * onCurrentDevice: boolean}}
+ */
+var SupervisedUser;
+
cr.define('signin', function() {
/** @interface */
function ProfileBrowserProxy() {}
@@ -40,16 +47,26 @@ cr.define('signin', function() {
},
/**
+ * Gets the list of existing supervised users.
+ * @param {string} profilePath Profile Path of the custodian.
+ * @return {Promise} A promise for the requested data.
+ * @private
+ */
+ getExistingSupervisedUsers: function(profilePath) {
+ assertNotReached();
+ },
+
+ /**
* Creates a profile.
* @param {string} profileName Name of the new profile.
* @param {string} profileIconUrl URL of the selected icon of the new
* profile.
* @param {boolean} isSupervised True if the new profile is supervised.
- * @param {string|undefined} supervisorProfilePath Profile path of the
- * supervisor if the new profile is supervised.
+ * @param {string} custodianProfilePath Profile path of the custodian if
+ * the new profile is supervised.
*/
createProfile: function(profileName, profileIconUrl, isSupervised,
- supervisorProfilePath) {
+ custodianProfilePath) {
assertNotReached();
},
@@ -104,11 +121,16 @@ cr.define('signin', function() {
},
/** @override */
+ getExistingSupervisedUsers: function(profilePath) {
+ return cr.sendWithPromise('getExistingSupervisedUsers', profilePath);
+ },
+
+ /** @override */
createProfile: function(profileName, profileIconUrl, isSupervised,
- supervisorProfilePath) {
+ custodianProfilePath) {
chrome.send('createProfile',
[profileName, profileIconUrl, false, isSupervised, '',
- supervisorProfilePath]);
+ custodianProfilePath]);
},
/** @override */

Powered by Google App Engine
This is Rietveld 408576698