Fix js based bustage from nsIDOMWindowInternal merge (bug 670235) r=bustage
authorMark Banner <bugzilla@standard8.plus.com>
Fri, 15 Jul 2011 18:47:05 +0100
changeset 8296 26c88a50b37169c68b1c3d80cd5e53d17c728b5d
parent 8295 70caf2978218414edf83a040c0410fc087b1aa26
child 8297 43bdfad505b34caa0b8f0323740b711dde4fb2c2
push id107
push userbugzilla@standard8.plus.com
push dateTue, 16 Aug 2011 23:11:19 +0000
treeherdercomm-aurora@cefe50ba1568 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbustage
bugs670235
Fix js based bustage from nsIDOMWindowInternal merge (bug 670235) r=bustage
mail/components/nsMailDefaultHandler.js
mail/test/mozmill/shared-modules/test-window-helpers.js
--- a/mail/components/nsMailDefaultHandler.js
+++ b/mail/components/nsMailDefaultHandler.js
@@ -39,17 +39,17 @@
 
 Components.utils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 const nsISupports              = Components.interfaces.nsISupports;
 
 const nsICommandLine           = Components.interfaces.nsICommandLine;
 const nsICommandLineHandler    = Components.interfaces.nsICommandLineHandler;
 const nsICommandLineValidator  = Components.interfaces.nsICommandLineValidator;
-const nsIDOMWindowInternal     = Components.interfaces.nsIDOMWindowInternal;
+const nsIDOMWindow             = Components.interfaces.nsIDOMWindow;
 const nsIFactory               = Components.interfaces.nsIFactory;
 const nsIFileURL               = Components.interfaces.nsIFileURL;
 const nsINetUtil               = Components.interfaces.nsINetUtil;
 const nsISupportsString        = Components.interfaces.nsISupportsString;
 const nsIURIFixup              = Components.interfaces.nsIURIFixup;
 const nsIURILoader             = Components.interfaces.nsIURILoader;
 const nsIWindowMediator        = Components.interfaces.nsIWindowMediator;
 const nsIWindowWatcher         = Components.interfaces.nsIWindowWatcher;
@@ -337,17 +337,17 @@ var nsMailDefaultHandler = {
 
     if (!uri && cmdLine.state != nsICommandLine.STATE_INITIAL_LAUNCH) {
       try {
         var wmed = Components.classes["@mozilla.org/appshell/window-mediator;1"]
                              .getService(nsIWindowMediator);
 
         var wlist = wmed.getEnumerator("mail:3pane");
         if (wlist.hasMoreElements()) {
-          var window = wlist.getNext().QueryInterface(nsIDOMWindowInternal);
+          var window = wlist.getNext().QueryInterface(nsIDOMWindow);
           window.focus();
           return;
         }
       }
       catch (e) {
         dump(e);
       }
     }
--- a/mail/test/mozmill/shared-modules/test-window-helpers.js
+++ b/mail/test/mozmill/shared-modules/test-window-helpers.js
@@ -281,17 +281,17 @@ var WindowWatcher = {
             : FIRST_WINDOW_EVER_TIMEOUT_MS,
           this._firstWindowOpened ? WINDOW_OPEN_CHECK_INTERVAL_MS
             : FIRST_WINDOW_CHECK_INTERVAL_MS,
           this))
       throw new Error("Timed out waiting for window open!");
     this.waitingForOpen = null;
     let xulWindow = this.waitingList[aWindowType];
     let domWindow = xulWindow.docShell.QueryInterface(Ci.nsIInterfaceRequestor)
-                                      .getInterface(Ci.nsIDOMWindowInternal);
+                                      .getInterface(Ci.nsIDOMWindow);
     delete this.waitingList[aWindowType];
     // spin the event loop to make sure any setTimeout 0 calls have gotten their
     //  time in the sun.
     controller.sleep(0);
     this._firstWindowOpened = true;
     // wrap the creation because 
     mark_action("winhelp", "new MozMillController()", [aWindowType]);
     let c = new controller.MozMillController(domWindow);
@@ -330,17 +330,17 @@ var WindowWatcher = {
   /**
    * This is the nsITimer notification we receive...
    */
   notify: function WindowWatcher_notify() {
     if (this.monitorizeOpen()) {
       // okay, the window is opened, and we should be in its event loop now.
       let xulWindow = this.waitingList[this.waitingForOpen];
       let domWindow = xulWindow.docShell.QueryInterface(Ci.nsIInterfaceRequestor)
-                                        .getInterface(Ci.nsIDOMWindowInternal);
+                                        .getInterface(Ci.nsIDOMWindow);
       let troller = new controller.MozMillController(domWindow);
       augment_controller(troller, this.waitingForOpen);
 
       delete this.waitingList[this.waitingForOpen];
       this._timer.cancel();
 
       // now we are waiting for it to close...
       this.waitingForClose = this.waitingForOpen;
@@ -507,17 +507,17 @@ var WindowWatcher = {
   },
 
   /**
    * Closing windows have the advantage of having to already have been loaded,
    *  so things like their windowtype are immediately available.
    */
   onCloseWindow: function WindowWatcher_onCloseWindow(aXULWindow) {
     let domWindow = aXULWindow.docShell.QueryInterface(Ci.nsIInterfaceRequestor)
-                                       .getInterface(Ci.nsIDOMWindowInternal);
+                                       .getInterface(Ci.nsIDOMWindow);
     let windowType =
       domWindow.document.documentElement.getAttribute("windowtype") ||
       domWindow.document.documentElement.getAttribute("id");
     mark_action("winhelp", "onCloseWindow",
                 [getWindowTypeForXulWindow(aXULWindow, true) +
                    " (" + getUniqueIdForXulWindow(aXULWindow) + ")"]);
     // XXX because of how we dance with things, equivalence is not gonna
     //  happen for us.  This is most pragmatic.
@@ -1314,30 +1314,30 @@ function describeEventElementInHierarchy
   else {
     win = elem;
   }
   let treeItem = win.QueryInterface(Ci.nsIInterfaceRequestor)
                   .getInterface(Ci.nsIWebNavigation)
                   .QueryInterface(Ci.nsIDocShellTreeItem);
   while (treeItem) {
     win = treeItem.QueryInterface(Ci.nsIInterfaceRequestor)
-                  .getInterface(Ci.nsIDOMWindowInternal);
+                  .getInterface(Ci.nsIDOMWindow);
     // capture the window itself
     arr.push("in");
     arr.push(normalize_for_json(win));
 
     let parentTreeItem = treeItem.parent;
     // same-type frame element? (easy case)
     if (win.frameElement) {
       arr.push("frame:");
       arr.push(normalize_for_json(win.frameElement));
     }
     else if (parentTreeItem) {
       let parentWin = parentTreeItem.QueryInterface(Ci.nsIInterfaceRequestor)
-                        .getInterface(Ci.nsIDOMWindowInternal);
+                        .getInterface(Ci.nsIDOMWindow);
       let frame = _findFrameElementForWindowInWindow(win, parentWin);
       arr.push("frame:");
       arr.push(normalize_for_json(frame));
     }
     treeItem = parentTreeItem;
   }
 
   return arr;
@@ -1697,17 +1697,17 @@ function captureWindowStatesForErrorRepo
   let windows = info.windows = [];
 
   let windowMediator = Cc["@mozilla.org/appshell/window-mediator;1"]
                          .getService(Ci.nsIWindowMediator);
 
   let enumerator = windowMediator.getEnumerator(null);
   let iWin=0;
   while (enumerator.hasMoreElements()) {
-    let win = enumerator.getNext().QueryInterface(Ci.nsIDOMWindowInternal);
+    let win = enumerator.getNext().QueryInterface(Ci.nsIDOMWindow);
 
     let winId = win.document.documentElement.getAttribute("windowtype") ||
                 win.document.documentElement.getAttribute("id") ||
                 ("unnamed:" + iWin);
 
     let openPopups =
       Array.prototype.slice.call(
           win.document.documentElement.getElementsByTagName("menupopup"))