Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: lib/main.js

Issue 29329263: Issue 3108 - Less hacky approach to disabling E10S compatibility shims (Closed)
Patch Set: Created Oct. 16, 2015, 9:03 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « lib/child/elemHide.js ('k') | lib/utils.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/main.js
===================================================================
--- a/lib/main.js
+++ b/lib/main.js
@@ -31,36 +31,16 @@ require("notification");
require("sync");
require("messageResponder");
require("ui");
function bootstrapChildProcesses()
{
let info = require("info");
- // Huge hack: we cannot opt out of individual compatibility shims (see
- // https://bugzilla.mozilla.org/show_bug.cgi?id=1167802). So the about
- // protocol shim will override our handler in the content process. Prevent
- // this by making sure it isn't messaged.
- try
- {
- let {AboutProtocolParent} = Cu.import("resource://gre/modules/RemoteAddonsParent.jsm", {});
- if (AboutProtocolParent && typeof AboutProtocolParent.registerFactory == "function")
- {
- let origRegisterFactory = AboutProtocolParent.registerFactory;
- AboutProtocolParent.registerFactory = function(addon, ...args)
- {
- if (addon != info.addonID)
- origRegisterFactory.call(this, addon, ...args);
- }
- onShutdown.add(() => AboutProtocolParent.registerFactory = origRegisterFactory);
- }
- }
- catch(e) {}
-
let processScript = info.addonRoot + "lib/child/bootstrap.js?" + Math.random();
let messageManager = Cc["@mozilla.org/parentprocessmessagemanager;1"]
.getService(Ci.nsIProcessScriptLoader)
.QueryInterface(Ci.nsIMessageBroadcaster);
messageManager.loadProcessScript(processScript, true);
messageManager.broadcastAsyncMessage("AdblockPlus:Info", info);
onShutdown.add(() => {
« no previous file with comments | « lib/child/elemHide.js ('k') | lib/utils.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld