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

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

Issue 2302483003: Pin keyboard improvements. (Closed)
Patch Set: Fixed patch set 1 errors. Created 4 years, 3 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 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 User pod row implementation. 6 * @fileoverview User pod row implementation.
7 */ 7 */
8 8
9 cr.define('login', function() { 9 cr.define('login', function() {
10 /** 10 /**
(...skipping 1109 matching lines...) Expand 10 before | Expand all | Expand 10 after
1120 if (visible && Oobe.getInstance().virtualKeyboardShown) 1120 if (visible && Oobe.getInstance().virtualKeyboardShown)
1121 return; 1121 return;
1122 1122
1123 var elements = this.getElementsByClassName('pin-tag'); 1123 var elements = this.getElementsByClassName('pin-tag');
1124 for (var i = 0; i < elements.length; ++i) 1124 for (var i = 0; i < elements.length; ++i)
1125 this.updatePinClass_(elements[i], visible); 1125 this.updatePinClass_(elements[i], visible);
1126 this.updatePinClass_(this, visible); 1126 this.updatePinClass_(this, visible);
1127 1127
1128 // Set the focus to the input element after showing/hiding pin keyboard. 1128 // Set the focus to the input element after showing/hiding pin keyboard.
1129 this.mainInput.focus(); 1129 this.mainInput.focus();
1130
1131 // Change the password placeholder based on pin keyboard visibility.
1132 this.passwordElement.placeholder = loadTimeData.getString(visible ?
1133 'pinKeyboardPlaceholderPinPassword' : 'passwordHint');
1130 }, 1134 },
1131 1135
1132 isPinShown: function() { 1136 isPinShown: function() {
1133 return this.classList.contains('pin-enabled'); 1137 return this.classList.contains('pin-enabled');
1134 }, 1138 },
1135 1139
1136 setUserPodIconType: function(userTypeClass) { 1140 setUserPodIconType: function(userTypeClass) {
1137 this.userTypeIconAreaElement.classList.add(userTypeClass); 1141 this.userTypeIconAreaElement.classList.add(userTypeClass);
1138 this.userTypeIconAreaElement.hidden = false; 1142 this.userTypeIconAreaElement.hidden = false;
1139 }, 1143 },
(...skipping 2433 matching lines...) Expand 10 before | Expand all | Expand 10 after
3573 if (pod && pod.multiProfilesPolicyApplied) { 3577 if (pod && pod.multiProfilesPolicyApplied) {
3574 pod.userTypeBubbleElement.classList.remove('bubble-shown'); 3578 pod.userTypeBubbleElement.classList.remove('bubble-shown');
3575 } 3579 }
3576 } 3580 }
3577 }; 3581 };
3578 3582
3579 return { 3583 return {
3580 PodRow: PodRow 3584 PodRow: PodRow
3581 }; 3585 };
3582 }); 3586 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698