Bug 439495 - remove references of "browser.download.manager.useWindow"
authorShawn Wilsher <sdwilsh@shawnwilsher.com>
Thu, 26 Jun 2008 11:51:38 -0400
changeset 15552 8a770f50ccd3c41ff6cb2892011edb95ec2921dc
parent 15551 515b6afa2d2a525a08ea36b45c6f41887f08843b
child 15553 dfb267af6f44d1d8b684a7a6e8958bf86289d674
push id309
push usersdwilsh@shawnwilsher.com
push dateThu, 26 Jun 2008 15:52:45 +0000
treeherdermozilla-central@8a770f50ccd3 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs439495
milestone1.9.1a1pre
Bug 439495 - remove references of "browser.download.manager.useWindow" This removes the use of the preference browser.download.manager.useWindow, which was redundant because we do not have any download manager UI that isn't in a window, and the preference browser.download.manager.showWhenStarting controls the appearance of the downloads window. Additionally, this removes the preference browser.download.manager.openDelay which was made obsolete long ago but not removed from firefox.js. r=gavin
browser/app/profile/firefox.js
toolkit/components/downloads/src/nsDownloadProxy.h
--- a/browser/app/profile/firefox.js
+++ b/browser/app/profile/firefox.js
@@ -234,19 +234,17 @@ pref("browser.urlbar.search.timeout", 10
 pref("browser.download.saveLinkAsFilenameTimeout", 1000);
 
 pref("browser.download.useDownloadDir", true);
 pref("browser.download.folderList", 0);
 pref("browser.download.manager.showAlertOnComplete", true);
 pref("browser.download.manager.showAlertInterval", 2000);
 pref("browser.download.manager.retention", 2);
 pref("browser.download.manager.showWhenStarting", true);
-pref("browser.download.manager.useWindow", true);
 pref("browser.download.manager.closeWhenDone", false);
-pref("browser.download.manager.openDelay", 0);
 pref("browser.download.manager.focusWhenStarting", false);
 pref("browser.download.manager.flashCount", 2);
 pref("browser.download.manager.addToRecentDocs", true);
 pref("browser.download.manager.quitBehavior", 0);
 pref("browser.download.manager.scanWhenDone", true);
 pref("browser.download.manager.resumeOnWakeDelay", 10000);
 
 // search engines URL
--- a/toolkit/components/downloads/src/nsDownloadProxy.h
+++ b/toolkit/components/downloads/src/nsDownloadProxy.h
@@ -42,17 +42,16 @@
 #include "nsIDownloadManager.h"
 #include "nsIPrefBranch.h"
 #include "nsIPrefService.h"
 #include "nsIMIMEInfo.h"
 #include "nsIFileURL.h"
 #include "nsIDownloadManagerUI.h"
 
 #define PREF_BDM_SHOWWHENSTARTING "browser.download.manager.showWhenStarting"
-#define PREF_BDM_USEWINDOW "browser.download.manager.useWindow"
 #define PREF_BDM_FOCUSWHENSTARTING "browser.download.manager.focusWhenStarting"
 
 class nsDownloadProxy : public nsITransfer
 {
 public:
 
   nsDownloadProxy() { }
   virtual ~nsDownloadProxy() { }
@@ -78,21 +77,17 @@ public:
     nsCOMPtr<nsIPrefService> prefs = do_GetService("@mozilla.org/preferences-service;1", &rv);
     NS_ENSURE_SUCCESS(rv, rv);
     nsCOMPtr<nsIPrefBranch> branch = do_QueryInterface(prefs);
 
     PRBool showDM = PR_TRUE;
     if (branch)
       branch->GetBoolPref(PREF_BDM_SHOWWHENSTARTING, &showDM);
 
-    PRBool useWindow = PR_TRUE;
-    if (branch)
-      branch->GetBoolPref(PREF_BDM_USEWINDOW, &useWindow);
-    
-    if (showDM && useWindow) {
+    if (showDM) {
       PRUint32 id;
       mInner->GetId(&id);
 
       nsCOMPtr<nsIDownloadManagerUI> dmui =
         do_GetService("@mozilla.org/download-manager-ui;1", &rv);
       NS_ENSURE_SUCCESS(rv, rv);
 
       PRBool visible;