Chromium Code Reviews| Index: chrome/browser/resources/chromeos/quick_unlock/pin_keyboard.js |
| diff --git a/chrome/browser/resources/chromeos/quick_unlock/pin_keyboard.js b/chrome/browser/resources/chromeos/quick_unlock/pin_keyboard.js |
| index de93c08df1b17741ac5612be76bb7a37cf141619..f478e854e88f462cddc4c5e3a216708def058f74 100644 |
| --- a/chrome/browser/resources/chromeos/quick_unlock/pin_keyboard.js |
| +++ b/chrome/browser/resources/chromeos/quick_unlock/pin_keyboard.js |
| @@ -57,6 +57,13 @@ Polymer({ |
| onNumberTap_: function(event, detail) { |
| var numberValue = event.target.getAttribute('value'); |
| this.value += numberValue; |
| + |
| + // If a number button is clicked, we do not want to switch focus to the |
| + // button, therefore we transfer focus back to the input, but if a number |
| + // button is tabbed into, it should keep focus, so users can use tab and |
| + // spacebar/return to enter their PIN. |
| + if (!event.target.classList.contains('keyboard-focus')) |
|
jdufault
2016/07/12 19:59:44
What about just casting event.target to the right
|
| + this.focus(); |
| }, |
| /** Fires a submit event with the current PIN value. */ |