LEFT | RIGHT |
1 /* | 1 /* |
2 * This Source Code is subject to the terms of the Mozilla Public License | 2 * This Source Code is subject to the terms of the Mozilla Public License |
3 * version 2.0 (the "License"). You can obtain a copy of the License at | 3 * version 2.0 (the "License"). You can obtain a copy of the License at |
4 * http://mozilla.org/MPL/2.0/. | 4 * http://mozilla.org/MPL/2.0/. |
5 */ | 5 */ |
6 | 6 |
7 "use strict"; | 7 "use strict"; |
8 | 8 |
9 (function(messageManager) | 9 (function(messageManager) |
10 { | 10 { |
11 const Cc = Components.classes; | 11 const Cc = Components.classes; |
12 const Ci = Components.interfaces; | 12 const Ci = Components.interfaces; |
13 const Cr = Components.results; | 13 const Cr = Components.results; |
14 const Cu = Components.utils; | 14 const Cu = Components.utils; |
15 | 15 |
16 let {Loader, main, unload} = Cu.import("resource://gre/modules/commonjs/toolki
t/loader.js", {}); | 16 let {Loader, main, unload} = Cu.import( |
| 17 "resource://gre/modules/commonjs/toolkit/loader.js", {} |
| 18 ); |
17 let {Services} = Cu.import("resource://gre/modules/Services.jsm", {}); | 19 let {Services} = Cu.import("resource://gre/modules/Services.jsm", {}); |
18 | 20 |
19 Cu.importGlobalProperties(["atob", "btoa", "File", "URL", "URLSearchParams", | 21 Cu.importGlobalProperties(["atob", "btoa", "File", "URL", "URLSearchParams", |
20 "TextDecoder", "TextEncoder"]); | 22 "TextDecoder", "TextEncoder"]); |
21 | 23 |
22 let shutdownHandlers = []; | 24 let shutdownHandlers = []; |
23 let onShutdown = | 25 let onShutdown = |
24 { | 26 { |
25 done: false, | 27 done: false, |
26 add: function(handler) | 28 add: function(handler) |
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
81 } | 83 } |
82 | 84 |
83 messageManager.addMessageListener("ElemHideHelper:Shutdown", shutdown); | 85 messageManager.addMessageListener("ElemHideHelper:Shutdown", shutdown); |
84 onShutdown.add(() => | 86 onShutdown.add(() => |
85 { | 87 { |
86 messageManager.removeMessageListener("ElemHideHelper:Shutdown", shutdown); | 88 messageManager.removeMessageListener("ElemHideHelper:Shutdown", shutdown); |
87 }); | 89 }); |
88 | 90 |
89 init(); | 91 init(); |
90 })(this); | 92 })(this); |
LEFT | RIGHT |