Bug 608628 - Remove obsolete aMask parameter from tabbrowser's addProgressListener method. r=gavin
authorDão Gottwald <dao@mozilla.com>
Wed, 23 Mar 2011 12:35:21 +0100
changeset 63660 cd6080e941363b54731349f57ff1aa7b49171ccb
parent 63659 1d50cf645e9aed89d65cbf7535fa3f5d4a118b48
child 63661 6e5df65b3dc01abec0c3399ecca3b68e0ed54778
push idunknown
push userunknown
push dateunknown
reviewersgavin
bugs608628
milestone2.0b13pre
Bug 608628 - Remove obsolete aMask parameter from tabbrowser's addProgressListener method. r=gavin
browser/base/content/browser.js
browser/base/content/tabbrowser.xml
--- a/browser/base/content/browser.js
+++ b/browser/base/content/browser.js
@@ -1434,17 +1434,17 @@ function prepareForStartup() {
   // enable global history
   try {
     gBrowser.docShell.QueryInterface(Components.interfaces.nsIDocShellHistory).useGlobalHistory = true;
   } catch(ex) {
     Components.utils.reportError("Places database may be locked: " + ex);
   }
 
   // hook up UI through progress listener
-  gBrowser.addProgressListener(window.XULBrowserWindow, Components.interfaces.nsIWebProgress.NOTIFY_ALL);
+  gBrowser.addProgressListener(window.XULBrowserWindow);
   gBrowser.addTabsProgressListener(window.TabsProgressListener);
 
   // setup our common DOMLinkAdded listener
   gBrowser.addEventListener("DOMLinkAdded", DOMLinkHandler, false);
 
   // setup our MozApplicationManifest listener
   gBrowser.addEventListener("MozApplicationManifest",
                             OfflineApps, false);
--- a/browser/base/content/tabbrowser.xml
+++ b/browser/base/content/tabbrowser.xml
@@ -1815,19 +1815,22 @@
           <![CDATA[
             this.getBrowserForTab(aTab).reload();
           ]]>
         </body>
       </method>
 
       <method name="addProgressListener">
         <parameter name="aListener"/>
-        <parameter name="aMask"/>
         <body>
           <![CDATA[
+            NS_ASSERT(arguments.length == 1,
+                      "gBrowser.addProgressListener was called with a second argument, " +
+                      "which is not supported. See bug 608628.");
+
             if (!this.mAddProgressListenerWasCalled) {
               this.mAddProgressListenerWasCalled = true;
               this.tabContainer.updateVisibility();
             }
 
             this.mProgressListeners.push(aListener);
           ]]>
         </body>