Chromium Code Reviews| Index: chrome/browser/resources/settings/reset_page/reset_profile_dialog.js |
| diff --git a/chrome/browser/resources/settings/reset_page/reset_profile_dialog.js b/chrome/browser/resources/settings/reset_page/reset_profile_dialog.js |
| index 4161d2905487f18fe24806bc8dc29a1f7847c282..12ced6d8fa0ee09f19a56d99ab0c8cc8785acf73 100644 |
| --- a/chrome/browser/resources/settings/reset_page/reset_profile_dialog.js |
| +++ b/chrome/browser/resources/settings/reset_page/reset_profile_dialog.js |
| @@ -32,6 +32,12 @@ Polymer({ |
| }, |
| /** @private */ |
| + resetRequestOrigin_: { |
|
hcarmona
2016/10/13 20:30:19
Please change to:
resetRequestOrigin: String,
Ha
alito
2016/10/13 21:27:28
Done.
|
| + type: String, |
| + value: '', |
| + }, |
| + |
| + /** @private */ |
| clearingInProgress_: { |
| type: Boolean, |
| value: false, |
| @@ -86,10 +92,14 @@ Polymer({ |
| settings.getCurrentRoute() == settings.Route.TRIGGERED_RESET_DIALOG; |
| if (this.isTriggered_) { |
| this.browserProxy_.getTriggeredResetToolName().then(function(name) { |
| + this.resetRequestOrigin_ = 'triggeredreset'; |
| this.triggeredResetToolName_ = name; |
| this.showDialog_(); |
| }.bind(this)); |
| } else { |
| + var origin = window.location.hash.slice(1).toLowerCase() == 'cct' ? |
|
hcarmona
2016/10/13 20:30:19
Please add a comment explaining why 'cct' is impor
alito
2016/10/13 21:27:28
Done.
|
| + 'cct' : settings.getQueryParameters().get('origin'); |
| + this.resetRequestOrigin_ = origin || ''; |
| this.showDialog_(); |
| } |
| }, |
| @@ -103,7 +113,7 @@ Polymer({ |
| onResetTap_: function() { |
| this.clearingInProgress_ = true; |
| this.browserProxy_.performResetProfileSettings( |
| - this.$.sendSettings.checked).then(function() { |
| + this.$.sendSettings.checked, this.resetRequestOrigin_).then(function() { |
| this.clearingInProgress_ = false; |
| if (this.$.dialog.open) |
| this.$.dialog.close(); |