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

Side by Side Diff: chrome/browser/resources/settings/reset_page/reset_page.js

Issue 2371303002: md-settings: add routing to chrome://settings/triggeredResetProfileSettings (Closed)
Patch Set: Nits Created 4 years, 2 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
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 /** 5 /**
6 * @fileoverview 6 * @fileoverview
7 * 'settings-reset-page' is the settings page containing reset 7 * 'settings-reset-page' is the settings page containing reset
8 * settings. 8 * settings.
9 * 9 *
10 * Example: 10 * Example:
(...skipping 15 matching lines...) Expand all
26 showPowerwashDialog_: Boolean, 26 showPowerwashDialog_: Boolean,
27 </if> 27 </if>
28 28
29 /** @private */ 29 /** @private */
30 allowPowerwash_: { 30 allowPowerwash_: {
31 type: Boolean, 31 type: Boolean,
32 value: cr.isChromeOS ? loadTimeData.getBoolean('allowPowerwash') : false 32 value: cr.isChromeOS ? loadTimeData.getBoolean('allowPowerwash') : false
33 }, 33 },
34 }, 34 },
35 35
36 /** @protected */ 36 /**
37 currentRouteChanged: function() { 37 * settings.RouteObserverBehavior
38 if (settings.getCurrentRoute() == settings.Route.RESET_DIALOG) { 38 * @param {!settings.Route} route
39 this.$.resetProfileDialog.get().open(); 39 * @protected
40 } 40 */
41 currentRouteChanged: function(route) {
42 var isTriggered = route == settings.Route.TRIGGERED_RESET_DIALOG;
43 if (isTriggered || route == settings.Route.RESET_DIALOG)
44 this.$.resetProfileDialog.get().open(isTriggered);
41 }, 45 },
42 46
43 /** @private */ 47 /** @private */
44 onShowResetProfileDialog_: function() { 48 onShowResetProfileDialog_: function() {
45 settings.navigateTo(settings.Route.RESET_DIALOG); 49 settings.navigateTo(settings.Route.RESET_DIALOG);
46 }, 50 },
47 51
48 /** @private */ 52 /** @private */
49 onResetProfileDialogClose_: function() { 53 onResetProfileDialogClose_: function() {
50 settings.navigateToPreviousRoute(); 54 settings.navigateToPreviousRoute();
51 }, 55 },
52 56
53 <if expr="chromeos"> 57 <if expr="chromeos">
54 /** @private */ 58 /** @private */
55 onShowPowerwashDialog_: function() { 59 onShowPowerwashDialog_: function() {
56 this.showPowerwashDialog_ = true; 60 this.showPowerwashDialog_ = true;
57 }, 61 },
58 62
59 /** @private */ 63 /** @private */
60 onPowerwashDialogClose_: function() { 64 onPowerwashDialogClose_: function() {
61 this.showPowerwashDialog_ = false; 65 this.showPowerwashDialog_ = false;
62 }, 66 },
63 </if> 67 </if>
64 }); 68 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698