diff options
author | janekptacijarabaci <janekptacijarabaci@seznam.cz> | 2018-04-29 09:07:42 +0200 |
---|---|---|
committer | janekptacijarabaci <janekptacijarabaci@seznam.cz> | 2018-04-29 09:07:42 +0200 |
commit | aff03b0a67c41cf7af5df9c9eef715a8b27a2667 (patch) | |
tree | aa2909ae4718f81c83c8cfb68c1f5a23485b3173 /browser/extensions/pocket/content/pocket-content-process.js | |
parent | bdb4ff581677ad1cd411b55a68c87534f9a64882 (diff) | |
parent | 11caf6ecb3cb8c84d2355a6c6e9580a290147e92 (diff) | |
download | UXP-aff03b0a67c41cf7af5df9c9eef715a8b27a2667.tar UXP-aff03b0a67c41cf7af5df9c9eef715a8b27a2667.tar.gz UXP-aff03b0a67c41cf7af5df9c9eef715a8b27a2667.tar.lz UXP-aff03b0a67c41cf7af5df9c9eef715a8b27a2667.tar.xz UXP-aff03b0a67c41cf7af5df9c9eef715a8b27a2667.zip |
Merge branch 'master' of https://github.com/MoonchildProductions/UXP into js_dom_performance-resource-timing_1
Diffstat (limited to 'browser/extensions/pocket/content/pocket-content-process.js')
-rw-r--r-- | browser/extensions/pocket/content/pocket-content-process.js | 54 |
1 files changed, 0 insertions, 54 deletions
diff --git a/browser/extensions/pocket/content/pocket-content-process.js b/browser/extensions/pocket/content/pocket-content-process.js deleted file mode 100644 index 9b158a0ed..000000000 --- a/browser/extensions/pocket/content/pocket-content-process.js +++ /dev/null @@ -1,54 +0,0 @@ -/* 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"; - -// This file is loaded as a process script, it will be loaded in the parent -// process as well as all content processes. - -const { utils: Cu } = Components; -Cu.import("resource://gre/modules/XPCOMUtils.jsm"); -Cu.import("resource://gre/modules/Services.jsm"); -Cu.import("chrome://pocket/content/AboutPocket.jsm"); - -function AboutPocketChildListener() { -} -AboutPocketChildListener.prototype = { - onStartup: function onStartup() { - - // Only do this in content processes since, as the broadcaster of this - // message, the parent process doesn't also receive it. We handlers - // the shutting down separately. - if (Services.appinfo.processType == - Services.appinfo.PROCESS_TYPE_CONTENT) { - - Services.cpmm.addMessageListener("PocketShuttingDown", this, true); - } - - AboutPocket.aboutSaved.register(); - AboutPocket.aboutSignup.register(); - }, - - onShutdown: function onShutdown() { - AboutPocket.aboutSignup.unregister(); - AboutPocket.aboutSaved.unregister(); - - Services.cpmm.removeMessageListener("PocketShuttingDown", this); - Cu.unload("chrome://pocket/content/AboutPocket.jsm"); - }, - - receiveMessage: function receiveMessage(message) { - switch (message.name) { - case "PocketShuttingDown": - this.onShutdown(); - break; - default: - break; - } - - return; - } -}; - -const listener = new AboutPocketChildListener(); -listener.onStartup(); |