mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-30 00:01:50 +00:00
Bug 1276341 - don't use Cu.import for event-emitter.js; r=jryans
MozReview-Commit-ID: BDvrMP8fRim --HG-- extra : rebase_source : a40ac300ff98f302bfbf5ce978172904426fa152
This commit is contained in:
parent
c9840ff9af
commit
ee883aab7f
@ -18,9 +18,7 @@ thisTestLeaksUncaughtRejectionsAndShouldBeFixed("TypeError: this.doc is undefine
|
||||
const toolId1 = "test-tool-1";
|
||||
const toolId2 = "test-tool-2";
|
||||
|
||||
var tempScope = {};
|
||||
Cu.import("resource://devtools/shared/event-emitter.js", tempScope);
|
||||
var EventEmitter = tempScope.EventEmitter;
|
||||
var EventEmitter = require("devtools/shared/event-emitter");
|
||||
|
||||
function test() {
|
||||
addTab("about:blank").then(runTests1);
|
||||
@ -209,7 +207,6 @@ function destroyToolbox(toolbox) {
|
||||
}
|
||||
|
||||
function finishUp() {
|
||||
tempScope = null;
|
||||
gBrowser.removeCurrentTab();
|
||||
finish();
|
||||
}
|
||||
|
@ -16,7 +16,6 @@ const NS_XHTML = "http://www.w3.org/1999/xhtml";
|
||||
const XUL_NS = "http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul";
|
||||
|
||||
loader.lazyImporter(this, "PluralForm", "resource://gre/modules/PluralForm.jsm");
|
||||
loader.lazyImporter(this, "EventEmitter", "resource://devtools/shared/event-emitter.js");
|
||||
|
||||
loader.lazyGetter(this, "prefBranch", function () {
|
||||
return Services.prefs.getBranch(null)
|
||||
@ -32,6 +31,7 @@ loader.lazyRequireGetter(this, "ConsoleServiceListener", "devtools/shared/webcon
|
||||
loader.lazyRequireGetter(this, "gDevTools", "devtools/client/framework/devtools", true);
|
||||
loader.lazyRequireGetter(this, "gDevToolsBrowser", "devtools/client/framework/devtools-browser", true);
|
||||
loader.lazyRequireGetter(this, "nodeConstants", "devtools/shared/dom-node-constants", true);
|
||||
loader.lazyRequireGetter(this, "EventEmitter", "devtools/shared/event-emitter");
|
||||
|
||||
/**
|
||||
* A collection of utilities to help working with commands
|
||||
|
@ -5,7 +5,7 @@
|
||||
const {Cc, Ci, Cu, Cr} = require("chrome");
|
||||
const promise = require("promise");
|
||||
|
||||
const {EventEmitter} = Cu.import("resource://devtools/shared/event-emitter.js", {});
|
||||
const EventEmitter = require("devtools/shared/event-emitter");
|
||||
const {generateUUID} = Cc["@mozilla.org/uuid-generator;1"].getService(Ci.nsIUUIDGenerator);
|
||||
const {FileUtils} = Cu.import("resource://gre/modules/FileUtils.jsm", {});
|
||||
const {indexedDB} = require("sdk/indexed-db");
|
||||
|
@ -24,8 +24,7 @@
|
||||
const { utils: Cu } = Components;
|
||||
const { require } = Cu.import("resource://devtools/shared/Loader.jsm", {});
|
||||
const promise = require("promise");
|
||||
const { EventEmitter } =
|
||||
Cu.import("resource://devtools/shared/event-emitter.js", {});
|
||||
const EventEmitter = require("devtools/shared/event-emitter");
|
||||
const { Task } = require("devtools/shared/task");
|
||||
|
||||
SimpleTest.waitForExplicitFinish();
|
||||
|
Loading…
Reference in New Issue
Block a user