| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 | 6 * @fileoverview |
| 7 * 'settings-quick-unlock-setup-pin' is the settings page for choosing a PIN. | 7 * 'settings-quick-unlock-setup-pin' is the settings page for choosing a PIN. |
| 8 * | 8 * |
| 9 * Example: | 9 * Example: |
| 10 * | 10 * |
| (...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 97 }, | 97 }, |
| 98 | 98 |
| 99 observers: [ | 99 observers: [ |
| 100 'onRouteChanged_(currentRoute)', | 100 'onRouteChanged_(currentRoute)', |
| 101 'onSetModesChanged_(setModes)' | 101 'onSetModesChanged_(setModes)' |
| 102 ], | 102 ], |
| 103 | 103 |
| 104 /** @override */ | 104 /** @override */ |
| 105 attached: function() { | 105 attached: function() { |
| 106 this.resetState_(); | 106 this.resetState_(); |
| 107 this.askForPasswordIfUnset(); | 107 |
| 108 if (this.isScreenActive(QuickUnlockScreen.SETUP_PIN)) |
| 109 this.askForPasswordIfUnset(); |
| 108 }, | 110 }, |
| 109 | 111 |
| 110 /** | 112 /** |
| 111 * @param {!SettingsRoute} currentRoute | 113 * @param {!SettingsRoute} currentRoute |
| 112 * @private | 114 * @private |
| 113 */ | 115 */ |
| 114 onRouteChanged_: function(currentRoute) { | 116 onRouteChanged_: function(currentRoute) { |
| 115 if (this.isScreenActive(QuickUnlockScreen.SETUP_PIN)) { | 117 if (this.isScreenActive(QuickUnlockScreen.SETUP_PIN)) { |
| 116 this.askForPasswordIfUnset(); | 118 this.askForPasswordIfUnset(); |
| 117 } else { | 119 } else { |
| (...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 291 * @return {string} | 293 * @return {string} |
| 292 */ | 294 */ |
| 293 getContinueMessage_: function(isConfirmStep) { | 295 getContinueMessage_: function(isConfirmStep) { |
| 294 if (!isConfirmStep) | 296 if (!isConfirmStep) |
| 295 return this.i18n('quickUnlockConfigurePinContinueButton'); | 297 return this.i18n('quickUnlockConfigurePinContinueButton'); |
| 296 return this.i18n('save'); | 298 return this.i18n('save'); |
| 297 }, | 299 }, |
| 298 }); | 300 }); |
| 299 | 301 |
| 300 })(); | 302 })(); |
| OLD | NEW |