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

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

Issue 2722083003: MD Settings: Change "view reported settings" string. (Closed)
Patch Set: Fix Created 3 years, 9 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 * 7 *
8 * 'settings-reset-profile-dialog' is the dialog shown for clearing profile 8 * 'settings-reset-profile-dialog' is the dialog shown for clearing profile
9 * settings. A triggered variant of this dialog can be shown under certain 9 * settings. A triggered variant of this dialog can be shown under certain
10 * circumstances. See triggered_profile_resetter.h for when the triggered 10 * circumstances. See triggered_profile_resetter.h for when the triggered
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 return loadTimeData.getStringF('resetPageTitle'); 68 return loadTimeData.getStringF('resetPageTitle');
69 }, 69 },
70 70
71 /** @override */ 71 /** @override */
72 ready: function() { 72 ready: function() {
73 this.browserProxy_ = settings.ResetBrowserProxyImpl.getInstance(); 73 this.browserProxy_ = settings.ResetBrowserProxyImpl.getInstance();
74 74
75 this.addEventListener('cancel', function() { 75 this.addEventListener('cancel', function() {
76 this.browserProxy_.onHideResetProfileDialog(); 76 this.browserProxy_.onHideResetProfileDialog();
77 }.bind(this)); 77 }.bind(this));
78
79 this.$$('paper-checkbox a').addEventListener(
80 'tap', this.onShowReportedSettingsTap_.bind(this));
Dan Beam 2017/03/01 20:29:37 is addEventListener('tap') the same as listen('tap
dpapad 2017/03/01 20:37:49 Yes, it is triggered either way. The problem I see
dpapad 2017/03/01 20:42:59 Fixed by adding a listener for keydown, see latest
78 }, 81 },
79 82
80 /** @private */ 83 /** @private */
81 showDialog_: function() { 84 showDialog_: function() {
82 this.$.dialog.showModal(); 85 this.$.dialog.showModal();
83 this.browserProxy_.onShowResetProfileDialog(); 86 this.browserProxy_.onShowResetProfileDialog();
84 }, 87 },
85 88
86 /** @override */ 89 /** @override */
87 attached: function() { 90 attached: function() {
(...skipping 28 matching lines...) Expand all
116 this.$.sendSettings.checked, this.resetRequestOrigin_).then(function() { 119 this.$.sendSettings.checked, this.resetRequestOrigin_).then(function() {
117 this.clearingInProgress_ = false; 120 this.clearingInProgress_ = false;
118 if (this.$.dialog.open) 121 if (this.$.dialog.open)
119 this.$.dialog.close(); 122 this.$.dialog.close();
120 this.fire('reset-done'); 123 this.fire('reset-done');
121 }.bind(this)); 124 }.bind(this));
122 }, 125 },
123 126
124 /** 127 /**
125 * Displays the settings that will be reported in a new tab. 128 * Displays the settings that will be reported in a new tab.
129 * @param {!Event} e
126 * @private 130 * @private
127 */ 131 */
128 onShowReportedSettingsTap_: function() { 132 onShowReportedSettingsTap_: function(e) {
129 this.browserProxy_.showReportedSettings(); 133 this.browserProxy_.showReportedSettings();
134 e.stopPropagation();
130 }, 135 },
131 }); 136 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698