Bug 1501393 - Remove the await call to block on markuploaded. r=pbro
--- a/devtools/client/inspector/inspector.js
+++ b/devtools/client/inspector/inspector.js
@@ -5,16 +5,17 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
/* global window, BrowserLoader */
"use strict";
const Services = require("Services");
const promise = require("promise");
+const flags = require("devtools/shared/flags");
const EventEmitter = require("devtools/shared/event-emitter");
const {executeSoon} = require("devtools/shared/DevToolsUtils");
const {Toolbox} = require("devtools/client/framework/toolbox");
const ReflowTracker = require("devtools/client/inspector/shared/reflow-tracker");
const Store = require("devtools/client/inspector/store");
const InspectorStyleChangeTracker = require("devtools/client/inspector/shared/style-change-tracker");
// Use privileged promise in panel documents to prevent having them to freeze
@@ -286,17 +287,20 @@ Inspector.prototype = {
// We can display right panel with: tab bar, markup view and breadbrumb. Right after
// the splitter set the right and left panel sizes, in order to avoid resizing it
// during load of the inspector.
this.panelDoc.getElementById("inspector-main-content").style.visibility = "visible";
// Setup the sidebar panels.
this.setupSidebar();
- await this.once("markuploaded");
+ if (flags.testing) {
+ await this.once("markuploaded");
+ }
+
this.isReady = true;
// All the components are initialized. Take care of the remaining initialization
// and setup.
this.breadcrumbs = new HTMLBreadcrumbs(this);
this.setupExtensionSidebars();
this.setupSearchBox();
await this.setupToolbar();