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

Side by Side Diff: chrome/browser/resources/options/chromeos/quick_unlock_configure_overlay.js

Issue 2236213002: Add quick unlock Settings in options page (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: incorporate comments from jdufault@ Created 4 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 unified diff | Download patch
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 cr.define('options', function() {
6 var Page = cr.ui.pageManager.Page;
7 var PageManager = cr.ui.pageManager.PageManager;
8
9 /**
10 * QuickUnlockConfigureOverlay class
11 * Dialog that allows users to configure screen lock.
12 * @constructor
13 * @extends {cr.ui.pageManager.Page}
14 */
15 function QuickUnlockConfigureOverlay() {
16 Page.call(this, 'quickUnlockConfigureOverlay',
17 loadTimeData.getString('lockScreenTitle'),
18 'quick-unlock-configure-overlay');
19
20 }
21
22 cr.addSingletonGetter(QuickUnlockConfigureOverlay);
23
24 QuickUnlockConfigureOverlay.prototype = {
25 __proto__: Page.prototype,
26
27 /** @override */
28 initializePage: function() {
29 Page.prototype.initializePage.call(this);
30 document.querySelector('settings-lock-screen').addEventListener(
31 'close-overlay', this.handleCloseOverlay_.bind(this));
32 },
33
34 /** @override */
35 didClosePage: function() {
36 settings.navigateTo(settings.Route.PEOPLE);
37 },
38
39 /**
40 * Handler of window close-overlay event.
41 * @private
42 */
43 handleCloseOverlay_: function(e) {
44 QuickUnlockConfigureOverlay.dismiss();
45 }
46
47 };
48
49 QuickUnlockConfigureOverlay.dismiss = function() {
50 PageManager.closeOverlay();
51 };
52
53 // Export
54 return {
55 QuickUnlockConfigureOverlay: QuickUnlockConfigureOverlay
56 };
57 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698