2014-10-07 22:46:25 +04:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
|
|
|
|
|
|
|
"use strict";
|
|
|
|
|
2019-01-17 21:18:31 +03:00
|
|
|
const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
|
2014-10-07 22:46:25 +04:00
|
|
|
|
|
|
|
function MainProcessSingleton() {}
|
|
|
|
MainProcessSingleton.prototype = {
|
|
|
|
classID: Components.ID("{0636a680-45cb-11e4-916c-0800200c9a66}"),
|
|
|
|
QueryInterface: ChromeUtils.generateQI([
|
Bug 1649221: Update ChromeUtils.generateQI callers to pass strings. r=mccr8,remote-protocol-reviewers,marionette-reviewers,perftest-reviewers,webcompat-reviewers,geckoview-reviewers,preferences-reviewers,agi,whimboo,Bebe,twisniewski
Differential Revision: https://phabricator.services.mozilla.com/D81594
2020-07-11 02:58:28 +03:00
|
|
|
"nsIObserver",
|
|
|
|
"nsISupportsWeakReference",
|
2014-10-07 22:46:25 +04:00
|
|
|
]),
|
|
|
|
|
2016-12-30 02:34:54 +03:00
|
|
|
observe(subject, topic, data) {
|
2014-10-07 22:46:25 +04:00
|
|
|
switch (topic) {
|
|
|
|
case "app-startup": {
|
2019-06-12 20:49:56 +03:00
|
|
|
ChromeUtils.import(
|
|
|
|
"resource://gre/modules/CustomElementsListener.jsm",
|
|
|
|
null
|
|
|
|
);
|
2019-07-05 12:14:05 +03:00
|
|
|
|
2018-08-10 23:58:18 +03:00
|
|
|
Services.ppmm.loadProcessScript(
|
|
|
|
"chrome://global/content/process-content.js",
|
|
|
|
true
|
|
|
|
);
|
2014-10-07 22:46:25 +04:00
|
|
|
break;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
};
|
|
|
|
|
2019-01-30 05:32:37 +03:00
|
|
|
var EXPORTED_SYMBOLS = ["MainProcessSingleton"];
|