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

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

Issue 2108363002: Fix null deref when hiding the PIN keyboard. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@lkgr
Patch Set: Don't log PII Created 4 years, 6 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 | « ui/login/account_picker/screen_account_picker.js ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 0f854e0ba07a820dc14601dd4c059926d1345f2e..a30021a7be3af42249f812ad9d41ff7227bd3cc0 100644
--- a/ui/login/account_picker/user_pod_row.js
+++ b/ui/login/account_picker/user_pod_row.js
@@ -2574,14 +2574,29 @@ cr.define('login', function() {
},
/**
+ * Toggles pod PIN keyboard visiblity.
+ * @param {!user} username
+ * @param {boolean} visible
+ */
+ setPinVisibility: function(username, visible) {
+ var pod = this.getPodWithUsername_(username);
+ if (!pod) {
+ console.warn('Attempt to change pin visibility to ' + visible +
+ ' for missing pod');
+ return;
+ }
+
+ pod.setPinVisibility(visible);
+ },
+
+ /**
* Removes user pod from pod row.
- * @param {string} email User's email.
+ * @param {!user} username
*/
removeUserPod: function(username) {
var podToRemove = this.getPodWithUsername_(username);
if (podToRemove == null) {
- console.warn('Attempt to remove not existing pod for ' + username +
- '.');
+ console.warn('Attempt to remove pod that does not exist');
return;
}
this.removeChild(podToRemove);
« no previous file with comments | « ui/login/account_picker/screen_account_picker.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698