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

Side by Side Diff: ui/login/account_picker/screen_account_picker.js

Issue 2108363002: Fix null deref when hiding the PIN keyboard. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@lkgr
Patch Set: Don't log PII Created 4 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
« no previous file with comments | « no previous file | ui/login/account_picker/user_pod_row.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 341 matching lines...) Expand 10 before | Expand all | Expand 10 after
352 */ 352 */
353 setTouchViewState: function(isTouchViewEnabled) { 353 setTouchViewState: function(isTouchViewEnabled) {
354 $('pod-row').setTouchViewState(isTouchViewEnabled); 354 $('pod-row').setTouchViewState(isTouchViewEnabled);
355 }, 355 },
356 356
357 /** 357 /**
358 * Hides the PIN keyboard if it's active. 358 * Hides the PIN keyboard if it's active.
359 * @param {!user} user The user who can no longer enter a PIN. 359 * @param {!user} user The user who can no longer enter a PIN.
360 */ 360 */
361 disablePinKeyboardForUser: function(user) { 361 disablePinKeyboardForUser: function(user) {
362 var pinContainer = $('pin-container'); 362 $('pod-row').setPinVisibility(user, false);
363
364 // Transition opacity to 0, and when the transition is done hide the
365 // keyboard so it doesn't take layout space.
366 pinContainer.style.opacity = 0;
367 pinContainer.addEventListener('webkitTransitionEnd', function f(e) {
368 pinContainer.removeEventListener('webkitTransitionEnd', f);
369 pinContainer.hidden = true;
370 });
371 ensureTransitionEndEvent(pinContainer);
372 }, 363 },
373 364
374 /** 365 /**
375 * Updates the display name shown on a public session pod. 366 * Updates the display name shown on a public session pod.
376 * @param {string} userID The user ID of the public session 367 * @param {string} userID The user ID of the public session
377 * @param {string} displayName The new display name 368 * @param {string} displayName The new display name
378 */ 369 */
379 setPublicSessionDisplayName: function(userID, displayName) { 370 setPublicSessionDisplayName: function(userID, displayName) {
380 $('pod-row').setPublicSessionDisplayName(userID, displayName); 371 $('pod-row').setPublicSessionDisplayName(userID, displayName);
381 }, 372 },
(...skipping 21 matching lines...) Expand all
403 * @param {string} userID The user ID of the public session 394 * @param {string} userID The user ID of the public session
404 * @param {string} locale The locale to which this list of keyboard layouts 395 * @param {string} locale The locale to which this list of keyboard layouts
405 * applies 396 * applies
406 * @param {!Object} list List of available keyboard layouts 397 * @param {!Object} list List of available keyboard layouts
407 */ 398 */
408 setPublicSessionKeyboardLayouts: function(userID, locale, list) { 399 setPublicSessionKeyboardLayouts: function(userID, locale, list) {
409 $('pod-row').setPublicSessionKeyboardLayouts(userID, locale, list); 400 $('pod-row').setPublicSessionKeyboardLayouts(userID, locale, list);
410 } 401 }
411 }; 402 };
412 }); 403 });
OLDNEW
« no previous file with comments | « no previous file | ui/login/account_picker/user_pod_row.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698