Bug 1277910 - about:support should use nsIWindowMediator rather than nsIWindowWatcher. r=felipe, a=gchang
authorJustin Dolske <dolske@mozilla.com>
Mon, 01 Aug 2016 15:52:08 -0700
changeset 349641 d8fca4cfc0331e6a13384215f3c4e6ac7007b4f8
parent 349640 0230c3bb24cbdd52b043bcf4d2e250e9870a55aa
child 349642 924d05b7a076ae5984138702e7e950aa5254a6b4
push id1230
push userjlund@mozilla.com
push dateMon, 31 Oct 2016 18:13:35 +0000
treeherdermozilla-release@5e06e3766db2 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersfelipe, gchang
bugs1277910
milestone50.0a2
Bug 1277910 - about:support should use nsIWindowMediator rather than nsIWindowWatcher. r=felipe, a=gchang
toolkit/components/addoncompat/tests/addon/bootstrap.js
toolkit/components/addoncompat/tests/compat-addon/bootstrap.js
toolkit/modules/Troubleshoot.jsm
--- a/toolkit/components/addoncompat/tests/addon/bootstrap.js
+++ b/toolkit/components/addoncompat/tests/addon/bootstrap.js
@@ -10,22 +10,20 @@ Cu.import("resource://gre/modules/XPCOMU
 const baseURL = "http://mochi.test:8888/browser/" +
   "toolkit/components/addoncompat/tests/browser/";
 
 var contentSecManager = Cc["@mozilla.org/contentsecuritymanager;1"]
                           .getService(Ci.nsIContentSecurityManager);
 
 function forEachWindow(f)
 {
-  let wins = Services.ww.getWindowEnumerator("navigator:browser");
+  let wins = Services.wm.getEnumerator("navigator:browser");
   while (wins.hasMoreElements()) {
     let win = wins.getNext();
-    if (win.gBrowser) {
-      f(win);
-    }
+    f(win);
   }
 }
 
 function addLoadListener(target, listener)
 {
   target.addEventListener("load", function handler(event) {
     target.removeEventListener("load", handler, true);
     return listener(event);
--- a/toolkit/components/addoncompat/tests/compat-addon/bootstrap.js
+++ b/toolkit/components/addoncompat/tests/compat-addon/bootstrap.js
@@ -7,22 +7,20 @@ Cu.import("resource://gre/modules/Servic
 Cu.import("resource://gre/modules/BrowserUtils.jsm");
 Cu.import("resource://gre/modules/XPCOMUtils.jsm");
 
 const baseURL = "http://mochi.test:8888/browser/" +
   "toolkit/components/addoncompat/tests/browser/";
 
 function forEachWindow(f)
 {
-  let wins = Services.ww.getWindowEnumerator("navigator:browser");
+  let wins = Services.wm.getEnumerator("navigator:browser");
   while (wins.hasMoreElements()) {
     let win = wins.getNext();
-    if (win.gBrowser) {
-      f(win);
-    }
+    f(win);
   }
 }
 
 function addLoadListener(target, listener)
 {
   function frameScript() {
     addEventListener("load", function handler(event) {
       removeEventListener("load", handler, true);
--- a/toolkit/modules/Troubleshoot.jsm
+++ b/toolkit/modules/Troubleshoot.jsm
@@ -204,17 +204,17 @@ var dataProviders = {
                        getService(Ci.nsIURLFormatter);
     try {
       data.supportURL = urlFormatter.formatURLPref("app.support.baseURL");
     }
     catch (e) {}
 
     data.numTotalWindows = 0;
     data.numRemoteWindows = 0;
-    let winEnumer = Services.ww.getWindowEnumerator("navigator:browser");
+    let winEnumer = Services.wm.getEnumerator("navigator:browser");
     while (winEnumer.hasMoreElements()) {
       data.numTotalWindows++;
       let remote = winEnumer.getNext().
                    QueryInterface(Ci.nsIInterfaceRequestor).
                    getInterface(Ci.nsIWebNavigation).
                    QueryInterface(Ci.nsILoadContext).
                    useRemoteTabs;
       if (remote) {