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

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

Issue 2634493005: MD Settings: Site exceptions, close action menu when list changes. (Closed)
Patch Set: Adding test. Created 3 years, 11 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 | « no previous file | chrome/test/data/webui/settings/site_list_tests.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/resources/settings/site_settings/site_list.js
diff --git a/chrome/browser/resources/settings/site_settings/site_list.js b/chrome/browser/resources/settings/site_settings/site_list.js
index 8501b1304b61ea0970e512ebba4be0d9163f72d2..deb8f38ccd6fb9d6a29c73dc39197fc690dfdd66 100644
--- a/chrome/browser/resources/settings/site_settings/site_list.js
+++ b/chrome/browser/resources/settings/site_settings/site_list.js
@@ -223,11 +223,13 @@ Polymer({
if (this.allSites) {
this.getAllSitesList_().then(function(lists) {
this.processExceptions_(lists);
+ this.closeActionMenu_();
}.bind(this));
} else {
this.browserProxy_.getExceptionList(this.category).then(
function(exceptionList) {
this.processExceptions_([exceptionList]);
+ this.closeActionMenu_();
}.bind(this));
}
},
@@ -465,7 +467,9 @@ Polymer({
/** @private */
closeActionMenu_: function() {
this.actionMenuSite_ = null;
- /** @type {!CrActionMenuElement} */ (
- this.$$('dialog[is=cr-action-menu]')).close();
+ var actionMenu = /** @type {!CrActionMenuElement} */ (
+ this.$$('dialog[is=cr-action-menu]'));
+ if (actionMenu.open)
+ actionMenu.close();
},
});
« no previous file with comments | « no previous file | chrome/test/data/webui/settings/site_list_tests.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698