Upstream the changes from: Bug 888600 - Move ContentFrameMessageManager to WebIDL. Part 6: Mark some IDL interfaces as non-scriptable. r=bz.

Please see:
https://bugzilla.mozilla.org/show_bug.cgi?id=888600
https://hg.mozilla.org/mozilla-central/rev/83c87140dc3d
This commit is contained in:
Jonas Jenwald 2018-02-28 11:00:55 +01:00
parent 97faedba0c
commit 8b2c46dce7
2 changed files with 3 additions and 6 deletions

View File

@ -51,8 +51,7 @@ var PdfjsChromeUtils = {
this._browsers = new WeakSet();
if (!this._ppmm) {
// global parent process message manager (PPMM)
this._ppmm = Cc["@mozilla.org/parentprocessmessagemanager;1"].
getService(Ci.nsIMessageBroadcaster);
this._ppmm = Services.ppmm;
this._ppmm.addMessageListener("PDFJS:Parent:clearUserPref", this);
this._ppmm.addMessageListener("PDFJS:Parent:setIntPref", this);
this._ppmm.addMessageListener("PDFJS:Parent:setBoolPref", this);
@ -61,8 +60,7 @@ var PdfjsChromeUtils = {
this._ppmm.addMessageListener("PDFJS:Parent:isDefaultHandlerApp", this);
// global dom message manager (MMg)
this._mmg = Cc["@mozilla.org/globalmessagemanager;1"].
getService(Ci.nsIMessageListenerManager);
this._mmg = Services.mm;
this._mmg.addMessageListener("PDFJS:Parent:displayWarning", this);
this._mmg.addMessageListener("PDFJS:Parent:addEventListener", this);

View File

@ -35,8 +35,7 @@ var PdfjsContentUtils = {
// child *process* mm, or when loaded into the parent for in-content
// support the psuedo child process mm 'child PPMM'.
if (!this._mm) {
this._mm = Cc["@mozilla.org/childprocessmessagemanager;1"].
getService(Ci.nsISyncMessageSender);
this._mm = Services.cpmm;
this._mm.addMessageListener("PDFJS:Child:updateSettings", this);
Services.obs.addObserver(this, "quit-application");