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

Unified Diff: chrome/browser/resources/settings/people_page/lock_screen.js

Issue 2691943005: fix quick unlock config in options (Closed)
Patch Set: incorporate comments Created 3 years, 10 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: chrome/browser/resources/settings/people_page/lock_screen.js
diff --git a/chrome/browser/resources/settings/people_page/lock_screen.js b/chrome/browser/resources/settings/people_page/lock_screen.js
index 70365d15396bd034b04fa7129ca3d02ffbfd210d..321af4250ddcc78feabdfe17bfee9010291fae59 100644
--- a/chrome/browser/resources/settings/people_page/lock_screen.js
+++ b/chrome/browser/resources/settings/people_page/lock_screen.js
@@ -89,11 +89,8 @@ Polymer({
/** @override */
attached: function() {
- // currentRouteChanged is not called during the initial navigation. If the
- // user navigates directly to the lockScreen page, we still want to show the
- // password prompt page.
- this.currentRouteChanged(settings.Route.LOCK_SCREEN,
- settings.Route.LOCK_SCREEN);
+ // Show lock screen if current route has been set to LOCK_SCREEN.
+ this.showLockScreen_();
Dan Beam 2017/02/28 02:49:16 this probably ought to be like maybeShowLockScreen
xiaoyinh(OOO Sep 11-29) 2017/02/28 21:41:16 Thanks for the suggestion. I changed name to be "s
this.browserProxy_ = settings.FingerprintBrowserProxyImpl.getInstance();
},
@@ -201,4 +198,12 @@ Polymer({
onEditFingerprints_: function() {
settings.navigateTo(settings.Route.FINGERPRINT);
},
+
+ /** @private */
+ showLockScreen_: function() {
+ if (settings.getCurrentRoute() == settings.Route.LOCK_SCREEN &&
+ !this.setModes_) {
+ this.$.passwordPrompt.open();
+ }
+ },
});
« no previous file with comments | « chrome/browser/resources/options_resources.grd ('k') | chrome/browser/ui/webui/options/browser_options_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698