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

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

Issue 369893005: Implement new design for expanded public session pod design (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed ScreenLockerTest. Rebased. Created 6 years, 5 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 login.createScreen('AccountPickerScreen', 'account-picker', function() { 9 login.createScreen('AccountPickerScreen', 'account-picker', function() {
10 /** 10 /**
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
112 if (!podRow.preselectedPod) 112 if (!podRow.preselectedPod)
113 this.onShow(); 113 this.onShow();
114 }, 114 },
115 115
116 /** 116 /**
117 * Event handler invoked when the page is shown and ready. 117 * Event handler invoked when the page is shown and ready.
118 */ 118 */
119 onShow: function() { 119 onShow: function() {
120 if (!this.firstShown_) return; 120 if (!this.firstShown_) return;
121 this.firstShown_ = false; 121 this.firstShown_ = false;
122 // TODO(nkostylev): Enable animation back when session start jank
123 // is reduced. See http://crosbug.com/11116 http://crosbug.com/18307
124 // $('pod-row').startInitAnimation();
125 122
126 // Ensure that login is actually visible. 123 // Ensure that login is actually visible.
127 window.webkitRequestAnimationFrame(function() { 124 window.webkitRequestAnimationFrame(function() {
128 chrome.send('accountPickerReady'); 125 chrome.send('accountPickerReady');
129 chrome.send('loginVisible', ['account-picker']); 126 chrome.send('loginVisible', ['account-picker']);
130 }); 127 });
131 }, 128 },
132 129
133 /** 130 /**
134 * Event handler that is invoked just before the frame is hidden. 131 * Event handler that is invoked just before the frame is hidden.
(...skipping 28 matching lines...) Expand all
163 $('bubble').showContentForElement(activatedPod.mainInput, 160 $('bubble').showContentForElement(activatedPod.mainInput,
164 cr.ui.Bubble.Attachment.BOTTOM, 161 cr.ui.Bubble.Attachment.BOTTOM,
165 error, 162 error,
166 BUBBLE_OFFSET, BUBBLE_PADDING); 163 BUBBLE_OFFSET, BUBBLE_PADDING);
167 } 164 }
168 }, 165 },
169 166
170 /** 167 /**
171 * Loads given users in pod row. 168 * Loads given users in pod row.
172 * @param {array} users Array of user. 169 * @param {array} users Array of user.
173 * @param {boolean} animated Whether to use init animation.
174 * @param {boolean} showGuest Whether to show guest session button. 170 * @param {boolean} showGuest Whether to show guest session button.
175 */ 171 */
176 loadUsers: function(users, animated, showGuest) { 172 loadUsers: function(users, showGuest) {
177 $('pod-row').loadPods(users, animated); 173 $('pod-row').loadPods(users);
178 $('login-header-bar').showGuestButton = showGuest; 174 $('login-header-bar').showGuestButton = showGuest;
179 175
180 // The desktop User Manager can send the index of a pod that should be 176 // The desktop User Manager can send the index of a pod that should be
181 // initially focused. 177 // initially focused.
182 var hash = window.location.hash; 178 var hash = window.location.hash;
183 if (hash) { 179 if (hash) {
184 var podIndex = hash.substr(1); 180 var podIndex = hash.substr(1);
185 if (podIndex) 181 if (podIndex)
186 $('pod-row').focusPodByIndex(podIndex, false); 182 $('pod-row').focusPodByIndex(podIndex, false);
187 } 183 }
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after
307 303
308 /** 304 /**
309 * Shows a tooltip bubble explaining Easy Unlock. 305 * Shows a tooltip bubble explaining Easy Unlock.
310 */ 306 */
311 showEasyUnlockBubble: function() { 307 showEasyUnlockBubble: function() {
312 $('pod-row').showEasyUnlockBubble(); 308 $('pod-row').showEasyUnlockBubble();
313 } 309 }
314 }; 310 };
315 }); 311 });
316 312
OLDNEW
« no previous file with comments | « chrome/browser/resources/chromeos/login/login.html ('k') | chrome/browser/resources/login/user_pod_row.css » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698