Bug 1487065 - Implement popup-notification as a Custom Element r=MattN

Differential Revision: https://phabricator.services.mozilla.com/D17699
This commit is contained in:
Brian Grinstead
2019-02-07 22:16:26 +00:00
parent 9101dd7c9a
commit c8a487965d
45 changed files with 388 additions and 477 deletions

View File

@@ -228,7 +228,7 @@ class ExtensionControlledPopup {
// Setup the command handler.
let handleCommand = async (event) => {
panel.hidePopup();
if (event.originalTarget.getAttribute("anonid") == "button") {
if (event.originalTarget == popupnotification.button) {
// Main action is to keep changes.
await this.setConfirmation(extensionId);
} else {
@@ -271,7 +271,7 @@ class ExtensionControlledPopup {
let anchor = doc.getAnonymousElementByAttribute(
anchorButton, "class", "toolbarbutton-icon");
panel.hidden = false;
popupnotification.hidden = false;
popupnotification.show();
panel.openPopup(anchor);
}