Bug 767813 - Set the consumeoutsideclicks attribute on panels instead of calling popupBoxObject.setConsumeRollupEvent. r=enndeakin

This commit is contained in:
Dão Gottwald 2012-06-24 19:44:04 +02:00
parent ad23ddebf2
commit 9ccea67b7f
5 changed files with 3 additions and 11 deletions

View File

@ -187,9 +187,6 @@ var StarUI = {
this._itemId = aItemId !== undefined ? aItemId : this._itemId;
this.beginBatch();
// Consume dismiss clicks, see bug 400924
this.panel.popupBoxObject
.setConsumeRollupEvent(Ci.nsIPopupBoxObject.ROLLUP_CONSUME);
this.panel.openPopup(aAnchorElement, aPosition);
gEditItemOverlay.initPanel(this._itemId,

View File

@ -6707,10 +6707,6 @@ var gIdentityHandler = {
// the popup is actually needed
this._identityPopup.hidden = false;
// Tell the popup to consume dismiss clicks, to avoid bug 395314
this._identityPopup.popupBoxObject
.setConsumeRollupEvent(Ci.nsIPopupBoxObject.ROLLUP_CONSUME);
// Update the popup strings
this.setPopupMessages(this._identityBox.className);

View File

@ -137,6 +137,7 @@
footertype="promobox"
orient="vertical"
ignorekeys="true"
consumeoutsideclicks="true"
hidden="true"
onpopupshown="StarUI.panelShown(event);"
aria-labelledby="editBookmarkPanelTitle">
@ -259,6 +260,7 @@
type="arrow"
hidden="true"
noautofocus="true"
consumeoutsideclicks="true"
onpopupshown="gIdentityHandler.onPopupShown(event);"
level="top">
<hbox id="identity-popup-container" align="top">

View File

@ -302,10 +302,6 @@ const DownloadsPanel = {
return;
}
// Make sure that clicking outside the popup cannot reopen it accidentally.
this.panel.popupBoxObject.setConsumeRollupEvent(Ci.nsIPopupBoxObject
.ROLLUP_CONSUME);
// Ensure the anchor is visible. If that is not possible, show the panel
// anchored to the top area of the window, near the default anchor position.
DownloadsButton.getAnchor(function DP_OPIDR_callback(aAnchor) {

View File

@ -46,6 +46,7 @@
type="arrow"
orient="vertical"
level="top"
consumeoutsideclicks="true"
onpopupshown="DownloadsPanel.onPopupShown(event);"
onpopuphidden="DownloadsPanel.onPopupHidden(event);">
<!-- The following popup menu should be a child of the panel element,