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

Unified Diff: chrome/browser/resources/chromeos/sim_unlock.js

Issue 7736014: [cros] Process proper notification in SIM dialog. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: js focus fix Created 9 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/chromeos/cros/network_library.cc ('k') | chrome/browser/ui/webui/chromeos/sim_unlock_ui.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/resources/chromeos/sim_unlock.js
diff --git a/chrome/browser/resources/chromeos/sim_unlock.js b/chrome/browser/resources/chromeos/sim_unlock.js
index 597f2a2aaf3b0a85fdfeaa7dd681950bfdc16608..3d64aa8bfcb083a92ae32570bce1dd20d64bdbb1 100644
--- a/chrome/browser/resources/chromeos/sim_unlock.js
+++ b/chrome/browser/resources/chromeos/sim_unlock.js
@@ -103,8 +103,8 @@ cr.define('mobile', function() {
$('new-pin-input').value = '';
$('retype-new-pin-input').value = '';
$('choose-pin-overlay').hidden = false;
- $('old-pin-input').focus();
SimUnlock.enableChoosePinDialog(true);
+ $('old-pin-input').focus();
break;
case SimUnlock.SIM_LOCKED_NO_PIN_TRIES_LEFT:
$('locked-pin-no-tries-overlay').hidden = false;
@@ -234,6 +234,7 @@ cr.define('mobile', function() {
});
$('pin-input').addEventListener('keyup', function(event) {
$('enter-pin-confirm').disabled =
+ $('enter-pin-dismiss').disabled ||
this.value.length < SimUnlock.PIN_MIN_LENGTH;
});
$('enter-pin-confirm').addEventListener('click', function(event) {
@@ -264,6 +265,7 @@ cr.define('mobile', function() {
});
$('puk-input').addEventListener('keyup', function(event) {
$('enter-puk-confirm').disabled =
+ $('enter-puk-dismiss').disabled ||
this.value.length < SimUnlock.PUK_LENGTH;
});
$('enter-puk-confirm').addEventListener('click', function(event) {
@@ -287,6 +289,7 @@ cr.define('mobile', function() {
});
$('old-pin-input').addEventListener('keyup', function(event) {
$('choose-pin-confirm').disabled =
+ $('choose-pin-dismiss').disabled ||
this.value.length < SimUnlock.PIN_MIN_LENGTH ||
$('new-pin-input').value.length < SimUnlock.PIN_MIN_LENGTH ||
$('retype-new-pin-input').value.length < SimUnlock.PIN_MIN_LENGTH;
@@ -306,6 +309,7 @@ cr.define('mobile', function() {
var oldPinOk = SimUnlock.state != SimUnlock.SIM_NOT_LOCKED_CHANGE_PIN ||
$('old-pin-input').value.length >= SimUnlock.PIN_MIN_LENGTH;
$('choose-pin-confirm').disabled =
+ $('choose-pin-dismiss').disabled ||
this.value.length < SimUnlock.PIN_MIN_LENGTH ||
$('retype-new-pin-input').value.length < SimUnlock.PIN_MIN_LENGTH ||
!oldPinOk;
@@ -314,6 +318,7 @@ cr.define('mobile', function() {
var oldPinOk = SimUnlock.state != SimUnlock.SIM_NOT_LOCKED_CHANGE_PIN ||
$('old-pin-input').value.length >= SimUnlock.PIN_MIN_LENGTH;
$('choose-pin-confirm').disabled =
+ $('choose-pin-dismiss').disabled ||
this.value.length < SimUnlock.PIN_MIN_LENGTH ||
$('new-pin-input').value.length < SimUnlock.PIN_MIN_LENGTH ||
!oldPinOk;
« no previous file with comments | « chrome/browser/chromeos/cros/network_library.cc ('k') | chrome/browser/ui/webui/chromeos/sim_unlock_ui.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698