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

Unified Diff: chrome/browser/resources/settings/site_settings/site_data.js

Issue 2686063004: MD Settings: make blowing away per-origin data (i.e. cookies) easier (Closed)
Patch Set: 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
« no previous file with comments | « chrome/browser/resources/settings/site_settings/site_data.html ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/resources/settings/site_settings/site_data.js
diff --git a/chrome/browser/resources/settings/site_settings/site_data.js b/chrome/browser/resources/settings/site_settings/site_data.js
index ab87956c66256e9e918dbc3ba5a8ea3af5472d7f..84b9e89d36fe58cb39bf155ae28368e66b83b488 100644
--- a/chrome/browser/resources/settings/site_settings/site_data.js
+++ b/chrome/browser/resources/settings/site_settings/site_data.js
@@ -24,9 +24,6 @@ Polymer({
/** @private */
confirmationDeleteMsg_: String,
-
- /** @private */
- idToDelete_: String,
Dan Beam 2017/02/11 01:09:27 unused (afaict)
},
/** @override */
@@ -78,9 +75,8 @@ Polymer({
* @param {!Event} e
* @private
*/
- onConfirmDeleteMultipleSites_: function(e) {
+ onRemoveAllSitesTap_: function(e) {
e.preventDefault();
- this.idToDelete_ = ''; // Delete all.
this.confirmationDeleteMsg_ = loadTimeData.getString(
'siteSettingsCookieRemoveMultipleConfirmation');
this.$.confirmDeleteDialog.showModal();
@@ -91,26 +87,8 @@ Polymer({
* @private
*/
onConfirmDelete_: function() {
- if (this.idToDelete_ != '')
- this.onDeleteSite_();
Dan Beam 2017/02/11 01:09:27 never hit
- else
- this.onDeleteMultipleSites_();
this.$.confirmDeleteDialog.close();
- },
-
- /**
- * Deletes all site data for a given site.
- * @private
- */
- onDeleteSite_: function() {
Dan Beam 2017/02/11 01:09:27 never hit
- this.browserProxy.removeCookie(this.idToDelete_);
- },
- /**
- * Deletes site data for multiple sites.
- * @private
- */
- onDeleteMultipleSites_: function() {
if (this.filterString_.length == 0) {
this.removeAllCookies();
} else {
@@ -125,6 +103,16 @@ Polymer({
},
/**
+ * Deletes all site data for a given site.
+ * @param {Event} e
dpapad 2017/02/10 02:14:51 Nit: !Event
Dan Beam 2017/02/11 01:09:27 Done.
+ * @private
+ */
+ onRemoveSiteTap_: function(e) {
+ e.stopPropagation();
+ this.browserProxy.removeCookie(e.model.item.id);
+ },
+
+ /**
* @param {!{model: !{item: CookieDataSummaryItem}}} event
* @private
*/
« no previous file with comments | « chrome/browser/resources/settings/site_settings/site_data.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698