Bug 870625 - Electrolysis: Add-on installation from addons.mozilla.org should work. r=Mossop

This commit is contained in:
Tom Schuster 2013-08-09 12:23:49 -04:00
parent 5f16927c95
commit b5f8a2c970

View File

@ -183,13 +183,13 @@ amManager.prototype = {
};
}
var window = null;
try {
// Normal approach for single-process mode
window = aMessage.target.contentWindow;
} catch (e) {
if (aMessage.target.getAttribute("remote") == "true") {
// Fallback for multiprocess (e10s) mode. Should reimplement this
// properly with Window IDs when possible, see bug 596109.
window = aMessage.target.ownerDocument.defaultView;
} else {
// Normal approach for single-process mode
window = aMessage.target.contentWindow;
}
return this.installAddonsFromWebpage(payload.mimetype,
window, referer, payload.uris, payload.hashes, payload.names,