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

Unified Diff: ui/login/account_picker/user_pod_row.js

Issue 2326833002: Submit button incompatiable with desktop chrome. (Closed)
Patch Set: 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 side-by-side diff with in-line comments
Download patch
Index: ui/login/account_picker/user_pod_row.js
diff --git a/ui/login/account_picker/user_pod_row.js b/ui/login/account_picker/user_pod_row.js
index b5247b60a07b91fcd892aaf50991b5f9001841c9..7980bdc2b5e6d2d8e1d325d9d9878052535e8132 100644
--- a/ui/login/account_picker/user_pod_row.js
+++ b/ui/login/account_picker/user_pod_row.js
@@ -757,8 +757,10 @@ cr.define('login', function() {
this.handlePasswordKeyPress_.bind(this));
this.passwordElement.addEventListener('input',
this.handleInputChanged_.bind(this));
- this.submitButton.addEventListener('click',
- this.handleSubmitButtonClick_.bind(this));
+ if (this.submitButton) {
+ this.submitButton.addEventListener('click',
+ this.handleSubmitButtonClick_.bind(this));
+ }
this.imageElement.addEventListener('load',
this.parentNode.handlePodImageLoad.bind(this.parentNode, this));
@@ -1132,7 +1134,8 @@ cr.define('login', function() {
},
set showError(visible) {
- this.submitButton.classList.toggle('error-shown', visible);
+ if (this.submitButton)
+ this.submitButton.classList.toggle('error-shown', visible);
},
toggleTransitions: function(enable) {
@@ -1862,7 +1865,8 @@ cr.define('login', function() {
handleInputChanged_: function(e) {
if (this.pinKeyboard)
this.pinKeyboard.value = this.passwordElement.value;
- this.submitButton.disabled = this.passwordElement.value.length <= 0;
+ if (this.submitButton)
+ this.submitButton.disabled = this.passwordElement.value.length <= 0;
this.showError = false;
},

Powered by Google App Engine
This is Rietveld 408576698