From 4410b7de6535c889dc81f5408900983736228e8b Mon Sep 17 00:00:00 2001 From: Dave Camp Date: Wed, 1 May 2013 09:27:24 -0700 Subject: [PATCH] Bug 867485: Move the devtools loader into toolkit/ r=jwalker --- browser/base/content/nsContextMenu.js | 2 +- .../devtools/commandline/BuiltinCommands.jsm | 2 +- browser/devtools/commandline/test/helpers.js | 2 +- browser/devtools/debugger/test/head.js | 1 + .../test/browser_fontinspector.js | 3 +- browser/devtools/framework/connect/connect.js | 3 +- browser/devtools/framework/gDevTools.jsm | 185 +------------- .../framework/test/browser_toolbox_hosts.js | 3 + browser/devtools/framework/test/head.js | 2 +- browser/devtools/inspector/CmdInspect.jsm | 2 +- browser/devtools/inspector/test/head.js | 2 +- browser/devtools/inspector/test/helpers.js | 2 +- .../layoutview/test/browser_layoutview.js | 2 +- browser/devtools/markupview/test/head.js | 2 +- browser/devtools/netmonitor/test/head.js | 3 +- browser/devtools/profiler/test/head.js | 2 + browser/devtools/shared/DeveloperToolbar.jsm | 2 +- browser/devtools/shared/test/head.js | 2 +- browser/devtools/styleeditor/test/head.js | 2 +- browser/devtools/styleeditor/test/helpers.js | 2 +- .../devtools/styleinspector/computed-view.js | 4 +- .../styleinspector/computedview.xhtml | 2 +- .../devtools/styleinspector/cssruleview.xhtml | 2 +- browser/devtools/styleinspector/test/head.js | 3 + browser/devtools/tilt/CmdTilt.jsm | 2 +- .../test/browser_tilt_picking_inspector.js | 2 +- browser/devtools/tilt/test/head.js | 2 +- browser/devtools/webconsole/HUDService.jsm | 2 +- browser/devtools/webconsole/test/head.js | 1 + browser/devtools/webconsole/webconsole.js | 2 +- toolkit/devtools/Loader.jsm | 238 ++++++++++++++++++ .../devtools/webconsole/WebConsoleUtils.jsm | 2 +- 32 files changed, 280 insertions(+), 208 deletions(-) create mode 100644 toolkit/devtools/Loader.jsm diff --git a/browser/base/content/nsContextMenu.js b/browser/base/content/nsContextMenu.js index 3121a8b5a24..4e4635829cc 100644 --- a/browser/base/content/nsContextMenu.js +++ b/browser/base/content/nsContextMenu.js @@ -437,7 +437,7 @@ nsContextMenu.prototype = { }, inspectNode: function CM_inspectNode() { - let {devtools} = Cu.import("resource:///modules/devtools/gDevTools.jsm", {}); + let {devtools} = Cu.import("resource://gre/modules/devtools/Loader.jsm", {}); let gBrowser = this.browser.ownerDocument.defaultView.gBrowser; let tt = devtools.TargetFactory.forTab(gBrowser.selectedTab); return gDevTools.showToolbox(tt, "inspector").then(function(toolbox) { diff --git a/browser/devtools/commandline/BuiltinCommands.jsm b/browser/devtools/commandline/BuiltinCommands.jsm index 0977c29c3cd..278962813a1 100644 --- a/browser/devtools/commandline/BuiltinCommands.jsm +++ b/browser/devtools/commandline/BuiltinCommands.jsm @@ -20,7 +20,7 @@ Cu.import("resource:///modules/devtools/shared/event-emitter.js"); XPCOMUtils.defineLazyModuleGetter(this, "gDevTools", "resource:///modules/devtools/gDevTools.jsm"); XPCOMUtils.defineLazyModuleGetter(this, "devtools", - "resource:///modules/devtools/gDevTools.jsm"); + "resource://gre/modules/devtools/Loader.jsm"); /* CmdAddon ---------------------------------------------------------------- */ diff --git a/browser/devtools/commandline/test/helpers.js b/browser/devtools/commandline/test/helpers.js index f1204d2b96d..0f70286ae89 100644 --- a/browser/devtools/commandline/test/helpers.js +++ b/browser/devtools/commandline/test/helpers.js @@ -24,7 +24,7 @@ let require = (Cu.import("resource://gre/modules/devtools/Require.jsm", {})).req Components.utils.import("resource:///modules/devtools/gcli.jsm", {}); let console = (Cu.import("resource://gre/modules/devtools/Console.jsm", {})).console; -let devtools = (Cu.import("resource:///modules/devtools/gDevTools.jsm", {})).devtools; +let devtools = (Cu.import("resource://gre/modules/devtools/Loader.jsm", {})).devtools; let TargetFactory = devtools.TargetFactory; let Promise = (Cu.import("resource://gre/modules/commonjs/sdk/core/promise.js", {})).Promise; diff --git a/browser/devtools/debugger/test/head.js b/browser/devtools/debugger/test/head.js index d12cbd5fbde..818e61d63bd 100644 --- a/browser/devtools/debugger/test/head.js +++ b/browser/devtools/debugger/test/head.js @@ -12,6 +12,7 @@ Cu.import("resource://gre/modules/devtools/dbg-server.jsm", tempScope); Cu.import("resource://gre/modules/devtools/dbg-client.jsm", tempScope); Cu.import("resource:///modules/source-editor.jsm", tempScope); Cu.import("resource:///modules/devtools/gDevTools.jsm", tempScope); +Cu.import("resource://gre/modules/devtools/Loader.jsm", tempScope); let Services = tempScope.Services; let SourceEditor = tempScope.SourceEditor; let DebuggerServer = tempScope.DebuggerServer; diff --git a/browser/devtools/fontinspector/test/browser_fontinspector.js b/browser/devtools/fontinspector/test/browser_fontinspector.js index 0dfdc35273a..e57fe609325 100644 --- a/browser/devtools/fontinspector/test/browser_fontinspector.js +++ b/browser/devtools/fontinspector/test/browser_fontinspector.js @@ -2,7 +2,8 @@ http://creativecommons.org/publicdomain/zero/1.0/ */ let tempScope = {}; -let {devtools, gDevTools} = Cu.import("resource:///modules/devtools/gDevTools.jsm", {}); +let {gDevTools} = Cu.import("resource:///modules/devtools/gDevTools.jsm", {}); +let {devtools} = Cu.import("resource://gre/modules/devtools/Loader.jsm", {}); let TargetFactory = devtools.TargetFactory; let DOMUtils = Cc["@mozilla.org/inspector/dom-utils;1"].getService(Ci.inIDOMUtils); diff --git a/browser/devtools/framework/connect/connect.js b/browser/devtools/framework/connect/connect.js index 659cc6853a1..30e1ee05b59 100644 --- a/browser/devtools/framework/connect/connect.js +++ b/browser/devtools/framework/connect/connect.js @@ -10,7 +10,8 @@ const Cu = Components.utils; Cu.import('resource://gre/modules/XPCOMUtils.jsm'); Cu.import("resource://gre/modules/Services.jsm"); Cu.import("resource://gre/modules/devtools/dbg-client.jsm"); -let {devtools, gDevTools} = Cu.import("resource:///modules/devtools/gDevTools.jsm", {}); +let {gDevTools} = Cu.import("resource:///modules/devtools/gDevTools.jsm", {}); +let {devtools} = Cu.import("resource://gre/modules/devtools/Loader.jsm", {}); let gClient; let gConnectionTimeout; diff --git a/browser/devtools/framework/gDevTools.jsm b/browser/devtools/framework/gDevTools.jsm index 89f75b22ddb..bc143c186ec 100644 --- a/browser/devtools/framework/gDevTools.jsm +++ b/browser/devtools/framework/gDevTools.jsm @@ -4,192 +4,15 @@ "use strict"; -this.EXPORTED_SYMBOLS = [ "gDevTools", "DevTools", "gDevToolsBrowser", "devtools" ]; +this.EXPORTED_SYMBOLS = [ "gDevTools", "DevTools", "gDevToolsBrowser" ]; const { classes: Cc, interfaces: Ci, utils: Cu } = Components; Cu.import("resource://gre/modules/XPCOMUtils.jsm"); Cu.import("resource://gre/modules/Services.jsm"); Cu.import("resource:///modules/devtools/shared/event-emitter.js"); -Cu.import("resource://gre/modules/FileUtils.jsm"); -Cu.import("resource://gre/modules/NetUtil.jsm"); Cu.import("resource://gre/modules/commonjs/sdk/core/promise.js"); - -XPCOMUtils.defineLazyModuleGetter(this, "OS", "resource://gre/modules/osfile.jsm"); - -let loader = Cu.import("resource://gre/modules/commonjs/toolkit/loader.js", {}).Loader; - -// Used when the tools should be loaded from the Firefox package itself (the default) - -var BuiltinProvider = { - load: function(done) { - this.loader = new loader.Loader({ - paths: { - "": "resource://gre/modules/commonjs/", - "main" : "resource:///modules/devtools/main", - "devtools": "resource:///modules/devtools", - "devtools/toolkit": "resource://gre/modules/devtools" - }, - globals: {}, - }); - this.main = loader.main(this.loader, "main"); - - return Promise.resolve(undefined); - }, - - unload: function(reason) { - loader.unload(this.loader, reason); - delete this.loader; - }, -}; - -var SrcdirProvider = { - load: function(done) { - let srcdir = Services.prefs.getComplexValue("devtools.loader.srcdir", - Ci.nsISupportsString); - srcdir = OS.Path.normalize(srcdir.data.trim()); - let devtoolsDir = OS.Path.join(srcdir, "browser/devtools"); - let toolkitDir = OS.Path.join(srcdir, "toolkit/devtools"); - - this.loader = new loader.Loader({ - paths: { - "": "resource://gre/modules/commonjs/", - "devtools/toolkit": "file://" + toolkitDir, - "devtools": "file://" + devtoolsDir, - "main": "file://" + devtoolsDir + "/main.js" - }, - globals: {} - }); - - this.main = loader.main(this.loader, "main"); - - return this._writeManifest(devtoolsDir).then((data) => { - this._writeManifest(toolkitDir); - }).then(null, Cu.reportError); - }, - - unload: function(reason) { - loader.unload(this.loader, reason); - delete this.loader; - }, - - _readFile: function(filename) { - let deferred = Promise.defer(); - let file = new FileUtils.File(filename); - NetUtil.asyncFetch(file, (inputStream, status) => { - if (!Components.isSuccessCode(status)) { - deferred.reject(new Error("Couldn't load manifest: " + filename + "\n")); - return; - } - var data = NetUtil.readInputStreamToString(inputStream, inputStream.available()); - deferred.resolve(data); - }); - return deferred.promise; - }, - - _writeFile: function(filename, data) { - let deferred = Promise.defer(); - let file = new FileUtils.File(filename); - - var ostream = FileUtils.openSafeFileOutputStream(file) - - var converter = Cc["@mozilla.org/intl/scriptableunicodeconverter"]. - createInstance(Ci.nsIScriptableUnicodeConverter); - converter.charset = "UTF-8"; - var istream = converter.convertToInputStream(data); - NetUtil.asyncCopy(istream, ostream, (status) => { - if (!Components.isSuccessCode(status)) { - deferred.reject(new Error("Couldn't write manifest: " + filename + "\n")); - return; - } - - deferred.resolve(null); - }); - return deferred.promise; - }, - - _writeManifest: function(dir) { - return this._readFile(dir + "/jar.mn").then((data) => { - // The file data is contained within inputStream. - // You can read it into a string with - let entries = []; - let lines = data.split(/\n/); - let preprocessed = /^\s*\*/; - let contentEntry = new RegExp("^\\s+content/(\\w+)/(\\S+)\\s+\\((\\S+)\\)"); - for (let line of lines) { - if (preprocessed.test(line)) { - dump("Unable to override preprocessed file: " + line + "\n"); - continue; - } - let match = contentEntry.exec(line); - if (match) { - let entry = "override chrome://" + match[1] + "/content/" + match[2] + "\tfile://" + dir + "/" + match[3]; - entries.push(entry); - } - } - return this._writeFile(dir + "/chrome.manifest", entries.join("\n")); - }).then(() => { - Components.manager.addBootstrappedManifestLocation(new FileUtils.File(dir)); - }); - } -}; - -this.devtools = { - _provider: null, - - get main() this._provider.main, - - // This is a gross gross hack. In one place (computed-view.js) we use - // Iterator, but the addon-sdk loader takes Iterator off the global. - // Give computed-view.js a way to get back to the Iterator until we have - // a chance to fix that crap. - _Iterator: Iterator, - - setProvider: function(provider) { - if (provider === this._provider) { - return; - } - - if (this._provider) { - delete this.require; - this._provider.unload("newprovider"); - gDevTools._teardown(); - } - this._provider = provider; - this._provider.load(); - this.require = loader.Require(this._provider.loader, { id: "devtools" }) - - let exports = this._provider.main; - // Let clients find exports on this object. - Object.getOwnPropertyNames(exports).forEach(key => { - XPCOMUtils.defineLazyGetter(this, key, () => exports[key]); - }); - }, - - /** - * Choose a default tools provider based on the preferences. - */ - _chooseProvider: function() { - if (Services.prefs.prefHasUserValue("devtools.loader.srcdir")) { - this.setProvider(SrcdirProvider); - } else { - this.setProvider(BuiltinProvider); - } - }, - - /** - * Reload the current provider. - */ - reload: function() { - var events = devtools.require("sdk/system/events"); - events.emit("startupcache-invalidate", {}); - - this._provider.unload("reload"); - delete this._provider; - gDevTools._teardown(); - this._chooseProvider(); - }, -}; +Cu.import("resource://gre/modules/devtools/Loader.jsm"); const FORBIDDEN_IDS = new Set(["toolbox", ""]); @@ -868,5 +691,5 @@ gDevTools.on("toolbox-destroyed", gDevToolsBrowser._updateMenuCheckbox); Services.obs.addObserver(gDevToolsBrowser.destroy, "quit-application", false); -// Now load the tools. -devtools._chooseProvider(); +// Load the browser devtools main module as the loader's main module. +devtools.main("devtools/main"); diff --git a/browser/devtools/framework/test/browser_toolbox_hosts.js b/browser/devtools/framework/test/browser_toolbox_hosts.js index 1ba44699dad..5d451f01c8a 100644 --- a/browser/devtools/framework/test/browser_toolbox_hosts.js +++ b/browser/devtools/framework/test/browser_toolbox_hosts.js @@ -6,6 +6,9 @@ let temp = {} Cu.import("resource:///modules/devtools/gDevTools.jsm", temp); let DevTools = temp.DevTools; +Cu.import("resource://gre/modules/devtools/Loader.jsm", temp); +let devtools = temp.devtools; + let Toolbox = devtools.Toolbox; let toolbox, target; diff --git a/browser/devtools/framework/test/head.js b/browser/devtools/framework/test/head.js index a63e1eafc0c..84a144a7424 100644 --- a/browser/devtools/framework/test/head.js +++ b/browser/devtools/framework/test/head.js @@ -10,7 +10,7 @@ let console = tempScope.console; Components.utils.import("resource://gre/modules/commonjs/sdk/core/promise.js", tempScope); let Promise = tempScope.Promise; -let {devtools} = Components.utils.import("resource:///modules/devtools/gDevTools.jsm", {}); +let {devtools} = Components.utils.import("resource://gre/modules/devtools/Loader.jsm", {}); let TargetFactory = devtools.TargetFactory; /** diff --git a/browser/devtools/inspector/CmdInspect.jsm b/browser/devtools/inspector/CmdInspect.jsm index 2c6620f0287..517c86328ea 100644 --- a/browser/devtools/inspector/CmdInspect.jsm +++ b/browser/devtools/inspector/CmdInspect.jsm @@ -11,7 +11,7 @@ Cu.import('resource://gre/modules/XPCOMUtils.jsm'); XPCOMUtils.defineLazyModuleGetter(this, "gDevTools", "resource:///modules/devtools/gDevTools.jsm"); XPCOMUtils.defineLazyModuleGetter(this, "devtools", - "resource:///modules/devtools/gDevTools.jsm"); + "resource://gre/modules/devtools/Loader.jsm"); /** * 'inspect' command diff --git a/browser/devtools/inspector/test/head.js b/browser/devtools/inspector/test/head.js index 050fc3e6aac..abad1682bb9 100644 --- a/browser/devtools/inspector/test/head.js +++ b/browser/devtools/inspector/test/head.js @@ -9,7 +9,7 @@ let tempScope = {}; Cu.import("resource:///modules/devtools/LayoutHelpers.jsm", tempScope); let LayoutHelpers = tempScope.LayoutHelpers; -let {devtools} = Cu.import("resource:///modules/devtools/gDevTools.jsm", tempScope); +let {devtools} = Cu.import("resource://gre/modules/devtools/Loader.jsm", tempScope); let TargetFactory = devtools.TargetFactory; Components.utils.import("resource://gre/modules/devtools/Console.jsm", tempScope); diff --git a/browser/devtools/inspector/test/helpers.js b/browser/devtools/inspector/test/helpers.js index 97cc8eb153b..34685ea62fe 100644 --- a/browser/devtools/inspector/test/helpers.js +++ b/browser/devtools/inspector/test/helpers.js @@ -24,7 +24,7 @@ let require = (Cu.import("resource://gre/modules/devtools/Require.jsm", {})).req Components.utils.import("resource:///modules/devtools/gcli.jsm", {}); let console = (Cu.import("resource://gre/modules/devtools/Console.jsm", {})).console; -let {devtools} = Cu.import("resource:///modules/devtools/gDevTools.jsm", {}); +let {devtools} = Cu.import("resource://gre/modules/devtools/Loader.jsm", {}); let TargetFactory = devtools.TargetFactory; let Promise = (Cu.import("resource://gre/modules/commonjs/sdk/core/promise.js", {})).Promise; diff --git a/browser/devtools/layoutview/test/browser_layoutview.js b/browser/devtools/layoutview/test/browser_layoutview.js index 1c684b2a0a4..ca88b551ff2 100644 --- a/browser/devtools/layoutview/test/browser_layoutview.js +++ b/browser/devtools/layoutview/test/browser_layoutview.js @@ -1,7 +1,7 @@ /* Any copyright is dedicated to the Public Domain. http://creativecommons.org/publicdomain/zero/1.0/ */ -let {devtools} = Cu.import("resource:///modules/devtools/gDevTools.jsm", {}); +let {devtools} = Cu.import("resource://gre/modules/devtools/Loader.jsm", {}); let TargetFactory = devtools.TargetFactory; function test() { diff --git a/browser/devtools/markupview/test/head.js b/browser/devtools/markupview/test/head.js index 7e920ce195b..c1e1804bf6f 100644 --- a/browser/devtools/markupview/test/head.js +++ b/browser/devtools/markupview/test/head.js @@ -4,7 +4,7 @@ const Cu = Components.utils; -let {devtools} = Cu.import("resource:///modules/devtools/gDevTools.jsm", {}); +let {devtools} = Cu.import("resource://gre/modules/devtools/Loader.jsm", {}); let TargetFactory = devtools.TargetFactory; // Clear preferences that may be set during the course of tests. diff --git a/browser/devtools/netmonitor/test/head.js b/browser/devtools/netmonitor/test/head.js index 71be052fbfc..a2f7e05c44b 100644 --- a/browser/devtools/netmonitor/test/head.js +++ b/browser/devtools/netmonitor/test/head.js @@ -6,7 +6,8 @@ const { classes: Cc, interfaces: Ci, utils: Cu, results: Cr } = Components; let { Services } = Cu.import("resource://gre/modules/Services.jsm", {}); let { Promise } = Cu.import("resource://gre/modules/commonjs/sdk/core/promise.js", {}); -let { gDevTools, devtools } = Cu.import("resource:///modules/devtools/gDevTools.jsm", {}); +let { gDevTools } = Cu.import("resource:///modules/devtools/gDevTools.jsm", {}); +let { devtools } = Cu.import("resource://gre/modules/devtools/Loader.jsm", {}); let TargetFactory = devtools.TargetFactory; let Toolbox = devtools.Toolbox; diff --git a/browser/devtools/profiler/test/head.js b/browser/devtools/profiler/test/head.js index 0afb0aba2e0..651ddb2c75c 100644 --- a/browser/devtools/profiler/test/head.js +++ b/browser/devtools/profiler/test/head.js @@ -7,6 +7,8 @@ const REMOTE_ENABLED = "devtools.debugger.remote-enabled"; Cu.import("resource:///modules/devtools/gDevTools.jsm", temp); let gDevTools = temp.gDevTools; + +Cu.import("resource://gre/modules/devtools/Loader.jsm", temp); let TargetFactory = temp.devtools.TargetFactory; Cu.import("resource://gre/modules/devtools/dbg-server.jsm", temp); diff --git a/browser/devtools/shared/DeveloperToolbar.jsm b/browser/devtools/shared/DeveloperToolbar.jsm index dc68d4a6583..8bcb911efc5 100644 --- a/browser/devtools/shared/DeveloperToolbar.jsm +++ b/browser/devtools/shared/DeveloperToolbar.jsm @@ -31,7 +31,7 @@ XPCOMUtils.defineLazyModuleGetter(this, "PluralForm", "resource://gre/modules/PluralForm.jsm"); XPCOMUtils.defineLazyModuleGetter(this, "devtools", - "resource:///modules/devtools/gDevTools.jsm"); + "resource://gre/modules/devtools/Loader.jsm"); XPCOMUtils.defineLazyModuleGetter(this, "require", "resource://gre/modules/devtools/Require.jsm"); diff --git a/browser/devtools/shared/test/head.js b/browser/devtools/shared/test/head.js index 85173b0d5a3..d79c5c4c85a 100644 --- a/browser/devtools/shared/test/head.js +++ b/browser/devtools/shared/test/head.js @@ -2,7 +2,7 @@ * 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/. */ -let {devtools} = Cu.import("resource:///modules/devtools/gDevTools.jsm", {}); +let {devtools} = Cu.import("resource://gre/modules/devtools/Loader.jsm", {}); let TargetFactory = devtools.TargetFactory; /** diff --git a/browser/devtools/styleeditor/test/head.js b/browser/devtools/styleeditor/test/head.js index 1081abe14a0..d7d95d776d2 100644 --- a/browser/devtools/styleeditor/test/head.js +++ b/browser/devtools/styleeditor/test/head.js @@ -7,7 +7,7 @@ const TEST_BASE_HTTPS = "https://example.com/browser/browser/devtools/styleedito const TEST_HOST = 'mochi.test:8888'; let tempScope = {}; -Cu.import("resource:///modules/devtools/gDevTools.jsm", tempScope); +Cu.import("resource://gre/modules/devtools/Loader.jsm", tempScope); let TargetFactory = tempScope.devtools.TargetFactory; Components.utils.import("resource://gre/modules/devtools/Console.jsm", tempScope); let console = tempScope.console; diff --git a/browser/devtools/styleeditor/test/helpers.js b/browser/devtools/styleeditor/test/helpers.js index f1204d2b96d..0f70286ae89 100644 --- a/browser/devtools/styleeditor/test/helpers.js +++ b/browser/devtools/styleeditor/test/helpers.js @@ -24,7 +24,7 @@ let require = (Cu.import("resource://gre/modules/devtools/Require.jsm", {})).req Components.utils.import("resource:///modules/devtools/gcli.jsm", {}); let console = (Cu.import("resource://gre/modules/devtools/Console.jsm", {})).console; -let devtools = (Cu.import("resource:///modules/devtools/gDevTools.jsm", {})).devtools; +let devtools = (Cu.import("resource://gre/modules/devtools/Loader.jsm", {})).devtools; let TargetFactory = devtools.TargetFactory; let Promise = (Cu.import("resource://gre/modules/commonjs/sdk/core/promise.js", {})).Promise; diff --git a/browser/devtools/styleinspector/computed-view.js b/browser/devtools/styleinspector/computed-view.js index 8e3d9d76d3a..ec27a97db0a 100644 --- a/browser/devtools/styleinspector/computed-view.js +++ b/browser/devtools/styleinspector/computed-view.js @@ -14,8 +14,6 @@ Cu.import("resource://gre/modules/PluralForm.jsm"); Cu.import("resource://gre/modules/XPCOMUtils.jsm"); Cu.import("resource:///modules/devtools/Templater.jsm"); -Cu.import("resource:///modules/devtools/gDevTools.jsm"); - const FILTER_CHANGED_TIMEOUT = 300; const HTML_NS = "http://www.w3.org/1999/xhtml"; @@ -43,7 +41,7 @@ const XUL_NS = "http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"; function UpdateProcess(aWin, aGenerator, aOptions) { this.win = aWin; - this.iter = devtools._Iterator(aGenerator); + this.iter = _Iterator(aGenerator); this.onItem = aOptions.onItem || function() {}; this.onBatch = aOptions.onBatch || function () {}; this.onDone = aOptions.onDone || function() {}; diff --git a/browser/devtools/styleinspector/computedview.xhtml b/browser/devtools/styleinspector/computedview.xhtml index f459c0a4503..b890b1b17a7 100644 --- a/browser/devtools/styleinspector/computedview.xhtml +++ b/browser/devtools/styleinspector/computedview.xhtml @@ -35,7 +35,7 @@