Bug 1447611: Remove references to stylo prefs from Troubleshoot.jsm. r=jwatt
☠☠ backed out by 1fadea75f363 ☠ ☠
authorEmilio Cobos Álvarez <emilio@crisal.io>
Wed, 21 Mar 2018 12:48:11 +0100
changeset 462848 86c9fed44da23014876fdd6ec915f596d3b3ac23
parent 462847 bb84ac6e14689d1308dced13bab1b71f3f042713
child 462849 01ada1c5a95f3673687f98154c4b05350780bc43
push id9165
push userasasaki@mozilla.com
push dateThu, 26 Apr 2018 21:04:54 +0000
treeherdermozilla-beta@064c3804de2e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjwatt
bugs1447611
milestone61.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 1447611: Remove references to stylo prefs from Troubleshoot.jsm. r=jwatt MozReview-Commit-ID: 3tD2GRgE00o
toolkit/modules/Troubleshoot.jsm
toolkit/modules/tests/browser/browser_Troubleshoot.js
--- a/toolkit/modules/Troubleshoot.jsm
+++ b/toolkit/modules/Troubleshoot.jsm
@@ -11,19 +11,16 @@ ChromeUtils.import("resource://gre/modul
 ChromeUtils.import("resource://gre/modules/AppConstants.jsm");
 
 var Experiments;
 try {
   Experiments = ChromeUtils.import("resource:///modules/experiments/Experiments.jsm").Experiments;
 } catch (e) {
 }
 
-const env = Cc["@mozilla.org/process/environment;1"]
-              .getService(Ci.nsIEnvironment);
-
 // We use a preferences whitelist to make sure we only show preferences that
 // are useful for support and won't compromise the user's privacy.  Note that
 // entries are *prefixes*: for example, "accessibility." applies to all prefs
 // under the "accessibility.*" branch.
 const PREFS_WHITELIST = [
   "accessibility.",
   "apz.",
   "browser.cache.",
@@ -62,17 +59,16 @@ const PREFS_WHITELIST = [
   "general.useragent.",
   "gfx.",
   "html5.",
   "image.",
   "javascript.",
   "keyword.",
   "layers.",
   "layout.css.dpi",
-  "layout.css.servo.",
   "layout.display-list.",
   "media.",
   "mousewheel.",
   "network.",
   "permissions.default.image",
   "places.",
   "plugin.",
   "plugins.",
@@ -219,43 +215,16 @@ var dataProviders = {
                          .createInstance(Ci.nsISupportsPRUint64);
       let appinfo = Services.appinfo.QueryInterface(Ci.nsIObserver);
       appinfo.observe(e10sStatus, "getE10SBlocked", "");
       data.autoStartStatus = e10sStatus.data;
     } catch (e) {
       data.autoStartStatus = -1;
     }
 
-    data.styloBuild = AppConstants.MOZ_STYLO;
-    data.styloDefault = Services.prefs.getDefaultBranch(null)
-                                .getBoolPref("layout.css.servo.enabled", false);
-    data.styloResult = false;
-    // Perhaps a bit redundant in places, but this is easier to compare with the
-    // the real check in `nsLayoutUtils.cpp` to ensure they test the same way.
-    if (AppConstants.MOZ_STYLO) {
-      if (env.get("STYLO_FORCE_ENABLED")) {
-        data.styloResult = true;
-      } else if (env.get("STYLO_FORCE_DISABLED")) {
-        data.styloResult = false;
-      } else {
-        data.styloResult =
-          Services.prefs.getBoolPref("layout.css.servo.enabled", false);
-      }
-    }
-    data.styloChromeDefault =
-      Services.prefs.getDefaultBranch(null)
-              .getBoolPref("layout.css.servo.chrome.enabled", false);
-    data.styloChromeResult = false;
-    if (data.styloResult) {
-      let winUtils = Services.wm.getMostRecentWindow("").
-                     QueryInterface(Ci.nsIInterfaceRequestor).
-                     getInterface(Ci.nsIDOMWindowUtils);
-      data.styloChromeResult = winUtils.isStyledByServo;
-    }
-
     if (Services.policies) {
       data.policiesStatus = Services.policies.status;
     }
 
     const keyGoogle = Services.urlFormatter.formatURL("%GOOGLE_API_KEY%").trim();
     data.keyGoogleFound = keyGoogle != "no-google-api-key" && keyGoogle.length > 0;
 
     const keyMozilla = Services.urlFormatter.formatURL("%MOZILLA_API_KEY%").trim();
--- a/toolkit/modules/tests/browser/browser_Troubleshoot.js
+++ b/toolkit/modules/tests/browser/browser_Troubleshoot.js
@@ -139,31 +139,16 @@ const SNAPSHOT_SCHEMA = {
           type: "number",
         },
         currentContentProcesses: {
           type: "number",
         },
         maxContentProcesses: {
           type: "number",
         },
-        styloBuild: {
-          type: "boolean",
-        },
-        styloDefault: {
-          type: "boolean",
-        },
-        styloResult: {
-          type: "boolean",
-        },
-        styloChromeDefault: {
-          type: "boolean",
-        },
-        styloChromeResult: {
-          type: "boolean",
-        },
         policiesStatus: {
           type: "number",
         },
         keyGoogleFound: {
           type: "boolean",
         },
         keyMozillaFound: {
           type: "boolean",