Bug 1488377 - Use target.getFront to instantiate CssPropertiesFront; r=ochameau
☠☠ backed out by 0e28323e25ef ☠ ☠
authoryulia <ystartsev@mozilla.com>
Mon, 08 Oct 2018 10:58:01 +0000
changeset 495707 14f893f7de2dac98a5690d11507cadd1f6bd0030
parent 495706 e6bdfb617164e4e88919b6cc55491b411a962033
child 495708 7c9b5df95be88e0734bffae0d1a593216aa4ac08
push id9984
push userffxbld-merge
push dateMon, 15 Oct 2018 21:07:35 +0000
treeherdermozilla-beta@183d27ea8570 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersochameau
bugs1488377
milestone64.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1488377 - Use target.getFront to instantiate CssPropertiesFront; r=ochameau Differential Revision: https://phabricator.services.mozilla.com/D7886
devtools/client/inspector/inspector.js
devtools/shared/fronts/css-properties.js
--- a/devtools/client/inspector/inspector.js
+++ b/devtools/client/inspector/inspector.js
@@ -1449,17 +1449,16 @@ Inspector.prototype = {
       this._highlighters = null;
     }
 
     if (this._search) {
       this._search.destroy();
       this._search = null;
     }
 
-    const cssPropertiesDestroyer = this._cssProperties.front.destroy();
     const sidebarDestroyer = this.sidebar.destroy();
     const ruleViewSideBarDestroyer = this.ruleViewSideBar ?
       this.ruleViewSideBar.destroy() : null;
     const markupDestroyer = this._destroyMarkup();
 
     this.teardownToolbar();
 
     this.breadcrumbs.destroy();
@@ -1482,17 +1481,16 @@ Inspector.prototype = {
     this.resultsLength = null;
     this.searchBox = null;
     this.show3PaneTooltip = null;
     this.sidebar = null;
     this.store = null;
     this.telemetry = null;
 
     this._panelDestroyer = promise.all([
-      cssPropertiesDestroyer,
       markupDestroyer,
       sidebarDestroyer,
       ruleViewSideBarDestroyer
     ]);
 
     return this._panelDestroyer;
   },
 
--- a/devtools/shared/fronts/css-properties.js
+++ b/devtools/shared/fronts/css-properties.js
@@ -232,17 +232,17 @@ const initCssProperties = async function
   if (cachedCssProperties.has(client)) {
     return cachedCssProperties.get(client);
   }
 
   let db, front;
 
   // Get the list dynamically if the cssProperties actor exists.
   if (toolbox.target.hasActor("cssProperties")) {
-    front = CssPropertiesFront(client, toolbox.target.form);
+    front = toolbox.target.getFront("cssProperties");
     db = await front.getCSSDatabase();
   } else {
     // The target does not support this actor, so require a static list of supported
     // properties.
     db = CSS_PROPERTIES_DB;
   }
 
   const cssProperties = new CssProperties(normalizeCssData(db));