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

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

Issue 11672007: Fixed header bar UI behaviour. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Logging cleanup. Created 7 years, 11 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 | Annotate | Revision Log
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 Account picker screen implementation. 6 * @fileoverview Account picker screen implementation.
7 */ 7 */
8 8
9 cr.define('login', function() { 9 cr.define('login', function() {
10 /** 10 /**
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 onAfterShow: function(data) { 68 onAfterShow: function(data) {
69 $('pod-row').handleAfterShow(); 69 $('pod-row').handleAfterShow();
70 }, 70 },
71 71
72 /** 72 /**
73 * Event handler that is invoked just before the frame is shown. 73 * Event handler that is invoked just before the frame is shown.
74 * @param {string} data Screen init payload. 74 * @param {string} data Screen init payload.
75 */ 75 */
76 onBeforeShow: function(data) { 76 onBeforeShow: function(data) {
77 chrome.send('loginUIStateChanged', ['account-picker', true]); 77 chrome.send('loginUIStateChanged', ['account-picker', true]);
78 $('login-header-bar').signinUIState = SIGNIN_UI_STATE.ACCOUNT_PICKER;
78 chrome.send('hideCaptivePortal'); 79 chrome.send('hideCaptivePortal');
79 var podRow = $('pod-row'); 80 var podRow = $('pod-row');
80 podRow.handleBeforeShow(); 81 podRow.handleBeforeShow();
81 82
82 // If this is showing for the lock screen display the sign out button, 83 // If this is showing for the lock screen display the sign out button,
83 // hide the add user button and activate the locked user's pod. 84 // hide the add user button and activate the locked user's pod.
84 var lockedPod = podRow.lockedPod; 85 var lockedPod = podRow.lockedPod;
85 $('add-user-header-bar-item').hidden = !!lockedPod; 86 $('add-user-header-bar-item').hidden = !!lockedPod;
86 $('sign-out-user-item').hidden = !lockedPod; 87 $('sign-out-user-item').hidden = !lockedPod;
87 // In case of the preselected pod onShow will be called once pod 88 // In case of the preselected pod onShow will be called once pod
(...skipping 14 matching lines...) Expand all
102 103
103 chrome.send('accountPickerReady'); 104 chrome.send('accountPickerReady');
104 chrome.send('loginVisible', ['account-picker']); 105 chrome.send('loginVisible', ['account-picker']);
105 }, 106 },
106 107
107 /** 108 /**
108 * Event handler that is invoked just before the frame is hidden. 109 * Event handler that is invoked just before the frame is hidden.
109 */ 110 */
110 onBeforeHide: function() { 111 onBeforeHide: function() {
111 chrome.send('loginUIStateChanged', ['account-picker', false]); 112 chrome.send('loginUIStateChanged', ['account-picker', false]);
113 $('login-header-bar').signinUIState = SIGNIN_UI_STATE.HIDDEN;
112 $('pod-row').handleHide(); 114 $('pod-row').handleHide();
113 }, 115 },
114 116
115 /** 117 /**
116 * Shows sign-in error bubble. 118 * Shows sign-in error bubble.
117 * @param {number} loginAttempts Number of login attemps tried. 119 * @param {number} loginAttempts Number of login attemps tried.
118 * @param {HTMLElement} content Content to show in bubble. 120 * @param {HTMLElement} content Content to show in bubble.
119 */ 121 */
120 showErrorBubble: function(loginAttempts, error) { 122 showErrorBubble: function(loginAttempts, error) {
121 var activatedPod = $('pod-row').activatedPod; 123 var activatedPod = $('pod-row').activatedPod;
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
213 }; 215 };
214 // Start image loading. 216 // Start image loading.
215 // Add timestamp for wallpapers that are rotated over time. 217 // Add timestamp for wallpapers that are rotated over time.
216 image.src = 'chrome://wallpaper/' + new Date().getTime(); 218 image.src = 'chrome://wallpaper/' + new Date().getTime();
217 }; 219 };
218 220
219 return { 221 return {
220 AccountPickerScreen: AccountPickerScreen 222 AccountPickerScreen: AccountPickerScreen
221 }; 223 };
222 }); 224 });
OLDNEW
« no previous file with comments | « chrome/browser/resources/chromeos/login/header_bar.js ('k') | chrome/browser/resources/chromeos/login/screen_gaia_signin.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698