mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-26 22:32:46 +00:00
Bug 345774 - hang when closing the info-bar in Add-ons dialog. Also reverses stomping on extensions.xml by the checkin of bug 241015. r=sspitzer
This commit is contained in:
parent
338ab57f26
commit
2d7edc75a0
@ -1207,8 +1207,6 @@ const gAddonsMsgObserver = {
|
||||
case "addons-message-dismiss":
|
||||
break;
|
||||
}
|
||||
var addonsMsg = document.getElementById("addonsMsg");
|
||||
addonsMsg.hideMessage();
|
||||
if (gExtensionsView.selectedItem)
|
||||
gExtensionsView.selectedItem.focus();
|
||||
}
|
||||
|
@ -190,7 +190,8 @@
|
||||
</xul:hbox>
|
||||
<xul:hbox flex="1" class="blocklistedBox attention" align="center">
|
||||
<xul:label value="&blocklisted.label;" crop="end"/>
|
||||
<xul:label anonid="blocklistMoreInfo" class="text-link" value="&moreInfo.label;"/>
|
||||
<xul:label anonid="blocklistMoreInfo" class="text-link" value="&moreInfo.label;"
|
||||
onclick="openURL(this.getAttribute('moreInfoURL'));"/>
|
||||
</xul:hbox>
|
||||
</xul:vbox>
|
||||
<xul:hbox anonid="selectedButtons" flex="1" class="selectedButtons">
|
||||
@ -232,8 +233,8 @@
|
||||
var blocklistMoreInfo = document.getAnonymousElementByAttribute(this, "anonid", "blocklistMoreInfo");
|
||||
var prefs = Components.classes["@mozilla.org/preferences-service;1"]
|
||||
.getService(Components.interfaces.nsIPrefBranch);
|
||||
blocklistMoreInfo.setAttribute("onclick", "openURL(\"" +
|
||||
prefs.getCharPref("extensions.blocklist.detailsURL") + "\");");
|
||||
var url = prefs.getCharPref("extensions.blocklist.detailsURL");
|
||||
blocklistMoreInfo.setAttribute("moreInfoURL", url);
|
||||
} catch(e) {
|
||||
blocklistMoreInfo.hidden = true;
|
||||
}
|
||||
@ -522,9 +523,9 @@
|
||||
<xul:hbox hidden="true" anonid="messageClose" align="center" pack="end"
|
||||
class="addonsmessage-closebutton-box">
|
||||
<xul:toolbarbutton ondblclick="event.preventBubble();"
|
||||
anonid="closeButton"
|
||||
class="addonsmessage-close-button close-button"
|
||||
tooltiptext="&closeMessage.tooltip;"
|
||||
oncommand="this.parentNode.parentNode.hideMessage();"/>
|
||||
tooltiptext="&closeMessage.tooltip;"/>
|
||||
</xul:hbox>
|
||||
</content>
|
||||
<implementation implements="nsIAccessibleProvider">
|
||||
@ -582,11 +583,6 @@
|
||||
<body>
|
||||
<![CDATA[
|
||||
this.hidden = true;
|
||||
if (this._buttonElement.style.visibility == "hidden" && this.notifyData) {
|
||||
var os = Components.classes["@mozilla.org/observer-service;1"]
|
||||
.getService(Components.interfaces.nsIObserverService);
|
||||
os.notifyObservers(null, "addons-message-notification", this.notifyData);
|
||||
}
|
||||
if (this.queue.length > 0) {
|
||||
this.showMessage(this.queue[0][0], this.queue[0][1], this.queue[0][2],
|
||||
this.queue[0][3], this.queue[0][4], this.queue[0][5]);
|
||||
@ -699,11 +695,19 @@
|
||||
|
||||
<handlers>
|
||||
<handler event="command">
|
||||
if (event.originalTarget.getAttribute("anonid") == "messageButton") {
|
||||
<![CDATA[
|
||||
var id = event.originalTarget.getAttribute("anonid");
|
||||
if (id != "messageButton" && id != "closeButton")
|
||||
return;
|
||||
var notifyData = this.notifyData;
|
||||
if (!this.notifyData || id == "closeButton" &&
|
||||
this._buttonElement.style.visibility != "hidden")
|
||||
notifyData = "addons-message-dismiss";
|
||||
var os = Components.classes["@mozilla.org/observer-service;1"]
|
||||
.getService(Components.interfaces.nsIObserverService);
|
||||
os.notifyObservers(null, "addons-message-notification", this.notifyData);
|
||||
}
|
||||
os.notifyObservers(null, "addons-message-notification", notifyData);
|
||||
this.hideMessage();
|
||||
]]>
|
||||
</handler>
|
||||
</handlers>
|
||||
</binding>
|
||||
|
Loading…
Reference in New Issue
Block a user