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

Side by Side Diff: chrome/browser/resources/chromeos/login/screen_gaia_signin.js

Issue 16091003: Handle case in LMU creation when there are no managers available (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Review Created 7 years, 7 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 (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 /** 5 /**
6 * @fileoverview Oobe signin screen implementation. 6 * @fileoverview Oobe signin screen implementation.
7 */ 7 */
8 8
9 <include src="../../gaia_auth_host/gaia_auth_host.js"></include> 9 <include src="../../gaia_auth_host/gaia_auth_host.js"></include>
10 10
(...skipping 241 matching lines...) Expand 10 before | Expand all | Expand 10 after
252 if (data.passwordChanged) { 252 if (data.passwordChanged) {
253 reasonLabel.textContent = 253 reasonLabel.textContent =
254 loadTimeData.getString('signinScreenPasswordChanged'); 254 loadTimeData.getString('signinScreenPasswordChanged');
255 reasonLabel.hidden = false; 255 reasonLabel.hidden = false;
256 } else { 256 } else {
257 reasonLabel.hidden = true; 257 reasonLabel.hidden = true;
258 } 258 }
259 259
260 $('createAccount').hidden = !data.createAccount; 260 $('createAccount').hidden = !data.createAccount;
261 $('guestSignin').hidden = !data.guestSignin; 261 $('guestSignin').hidden = !data.guestSignin;
262 $('createManagedUserPane').hidden = !data.createLocallyManagedUser; 262 $('createManagedUserPane').hidden = !data.managedUsersEnabled;
263
264 $('createManagedUserLinkPlaceholder').hidden =
265 !data.managedUsersCanCreate;
266 $('createManagedUserNoManagerText').hidden = data.managedUsersCanCreate;
267
263 // Allow cancellation of screen only when user pods can be displayed. 268 // Allow cancellation of screen only when user pods can be displayed.
264 this.cancelAllowed_ = data.isShowUsers && $('pod-row').pods.length; 269 this.cancelAllowed_ = data.isShowUsers && $('pod-row').pods.length;
265 $('login-header-bar').allowCancel = this.cancelAllowed_; 270 $('login-header-bar').allowCancel = this.cancelAllowed_;
266 271
267 // Sign-in right panel is hidden if all of its items are hidden. 272 // Sign-in right panel is hidden if all of its items are hidden.
268 var noRightPanel = $('gaia-signin-reason').hidden && 273 var noRightPanel = $('gaia-signin-reason').hidden &&
269 $('createAccount').hidden && 274 $('createAccount').hidden &&
270 $('guestSignin').hidden && 275 $('guestSignin').hidden &&
271 $('createManagedUserPane').hidden; 276 $('createManagedUserPane').hidden;
272 this.classList.toggle('no-right-panel', noRightPanel); 277 this.classList.toggle('no-right-panel', noRightPanel);
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after
425 * For more info see C++ class 'SnifferObserver' which calls this method. 430 * For more info see C++ class 'SnifferObserver' which calls this method.
426 * @param {number} error Error code. 431 * @param {number} error Error code.
427 */ 432 */
428 onFrameError: function(error) { 433 onFrameError: function(error) {
429 console.error('Gaia frame error = ' + error); 434 console.error('Gaia frame error = ' + error);
430 this.error_ = error; 435 this.error_ = error;
431 chrome.send('frameLoadingCompleted', [this.error_]); 436 chrome.send('frameLoadingCompleted', [this.error_]);
432 }, 437 },
433 }; 438 };
434 }); 439 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698