| Index: Source/devtools/front_end/Runtime.js
|
| diff --git a/Source/devtools/front_end/Runtime.js b/Source/devtools/front_end/Runtime.js
|
| index 9f0e5b6f2c5e3715b4b544b5664464a0d98039d6..31fbfb1223e582990a6276c68aace5ffd2a67142 100644
|
| --- a/Source/devtools/front_end/Runtime.js
|
| +++ b/Source/devtools/front_end/Runtime.js
|
| @@ -217,6 +217,8 @@ Runtime.startWorker = function(moduleName)
|
| }
|
| }
|
|
|
| +Runtime._coreModules = ["common", "host", "sdk", "ui", "components", "workspace", "bindings", "screencast", "toolbox", "main"];
|
| +
|
| Runtime.prototype = {
|
| /**
|
| * @param {!Array.<string>} configuration
|
| @@ -233,9 +235,17 @@ Runtime.prototype = {
|
| _registerModule: function(moduleName)
|
| {
|
| if (!this._descriptorsMap[moduleName]) {
|
| - var content = loadResource(moduleName + "/module.json");
|
| + var content;
|
| + // FIXME: This is a temp workaround to avoid core module loading attempts in the release mode.
|
| + // It should be removed when the new application loader is implemented.
|
| + if (Runtime._coreModules.indexOf(moduleName) === -1)
|
| + content = loadResource(moduleName + "/module.json");
|
| + else
|
| + content = "{}";
|
| +
|
| if (!content)
|
| throw new Error("Module is not defined: " + moduleName + " " + new Error().stack);
|
| +
|
| var module = /** @type {!Runtime.ModuleDescriptor} */ (self.eval("(" + content + ")"));
|
| module["name"] = moduleName;
|
| this._descriptorsMap[moduleName] = module;
|
| @@ -537,7 +547,10 @@ Runtime.Module.prototype = {
|
| this._manager.loadModule(dependencies[i]);
|
| if (this._descriptor.scripts) {
|
| if (Runtime.isReleaseMode()) {
|
| - loadScript(this._name + ".js");
|
| + // FIXME: This is a temp workaround to avoid core module loading attempts in the release mode.
|
| + // It should be removed when the new application loader is implemented.
|
| + if (Runtime._coreModules.indexOf(this._name) === -1)
|
| + loadScript(this._name + ".js");
|
| } else {
|
| var scripts = this._descriptor.scripts;
|
| for (var i = 0; i < scripts.length; ++i)
|
|
|