[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[vidalia-svn] r3502: Remove BrowserDirectoryFilename option and instead overload (in vidalia/branches/alt-launcher/src/vidalia: . config)



Author: sjmurdoch
Date: 2009-02-02 12:32:32 -0500 (Mon, 02 Feb 2009)
New Revision: 3502

Modified:
   vidalia/branches/alt-launcher/src/vidalia/config/vidaliasettings.cpp
   vidalia/branches/alt-launcher/src/vidalia/config/vidaliasettings.h
   vidalia/branches/alt-launcher/src/vidalia/mainwindow.cpp
Log:
Remove BrowserDirectoryFilename option and instead overload BrowserExecutable

Modified: vidalia/branches/alt-launcher/src/vidalia/config/vidaliasettings.cpp
===================================================================
--- vidalia/branches/alt-launcher/src/vidalia/config/vidaliasettings.cpp	2009-02-02 04:54:08 UTC (rev 3501)
+++ vidalia/branches/alt-launcher/src/vidalia/config/vidaliasettings.cpp	2009-02-02 17:32:32 UTC (rev 3502)
@@ -33,7 +33,6 @@
 #define SETTING_SHOW_MAINWINDOW_AT_START  "ShowMainWindowAtStart"
 #define SETTING_BROWSER_EXECUTABLE  "BrowserExecutable"
 #define SETTING_BROWSER_DIRECTORY   "BrowserDirectory"
-#define SETTING_BROWSER_DIRECTORY_FILENAME  "BrowserDirectoryFilename"
 #define SETTING_IM_EXECUTABLE       "IMExecutable"
 #define SETTING_RUN_PROXY_AT_START  "RunProxyAtStart"
 #define SETTING_PROXY_EXECUTABLE    "ProxyExecutable"
@@ -177,8 +176,9 @@
 #endif
 }
 
-/** Returns a fully-qualified path to the web browser, including the
- * executable name. */
+/** If browserDirectory is empty, returns a fully-qualified path to
+ * the web browser, including the executable name. If browserDirectory
+ * is set, then returns the basename of the configured web browser */
 QString
 VidaliaSettings::getBrowserExecutable() const
 {
@@ -208,20 +208,6 @@
   setValue(SETTING_BROWSER_DIRECTORY, browserDirectory);
 }
 
-/** Returns the basename of the the web browser to execute */
-QString
-VidaliaSettings::getBrowserDirectoryFilename() const
-{
-  return value(SETTING_BROWSER_DIRECTORY_FILENAME).toString();
-}
-
-/** Sets the basename of the the web browser to execute. */
-void
-VidaliaSettings::setBrowserDirectoryFilename(const QString &browserDirectoryFilename)
-{
-  setValue(SETTING_BROWSER_DIRECTORY_FILENAME, browserDirectoryFilename);
-}
-
 /** Returns a fully-qualified path to the IM client, including the
  * executable name. */
 QString

Modified: vidalia/branches/alt-launcher/src/vidalia/config/vidaliasettings.h
===================================================================
--- vidalia/branches/alt-launcher/src/vidalia/config/vidaliasettings.h	2009-02-02 04:54:08 UTC (rev 3501)
+++ vidalia/branches/alt-launcher/src/vidalia/config/vidaliasettings.h	2009-02-02 17:32:32 UTC (rev 3502)
@@ -62,8 +62,9 @@
   /** Set whether to run Vidalia on system boot. */
   void setRunVidaliaOnBoot(bool run);
 
-  /** Returns a fully-qualified path to the web browser, including the
-   * executable name. */
+  /** If browserDirectory is empty, returns a fully-qualified path to
+   * the web browser, including the executable name. If browserDirectory
+   * is set, then returns the basename of the configured web browser */
   QString getBrowserExecutable() const;
   /** Sets the location and name of the web browser executable to the given
    * string. If set to the empty string, the browser will not be started. */
@@ -75,11 +76,6 @@
    * If set to the empty string, the browser will not be started. */
   void setBrowserDirectory(const QString &browserDirectory);
 
-  /** Returns the basename of the the web browser to execute */
-  QString getBrowserDirectoryFilename() const;
-  /** Sets the basename of the the web browser to execute. */
-  void setBrowserDirectoryFilename(const QString &browserDirectoryFilename);
-
   /** Returns a fully-qualified path to the IM client, including the
    * executable name. */
   QString getIMExecutable() const;

Modified: vidalia/branches/alt-launcher/src/vidalia/mainwindow.cpp
===================================================================
--- vidalia/branches/alt-launcher/src/vidalia/mainwindow.cpp	2009-02-02 04:54:08 UTC (rev 3501)
+++ vidalia/branches/alt-launcher/src/vidalia/mainwindow.cpp	2009-02-02 17:32:32 UTC (rev 3502)
@@ -551,7 +551,7 @@
   VidaliaSettings settings;
 
   QString browserDirectory = settings.getBrowserDirectory();
-  QString browserDirectoryFilename = settings.getBrowserDirectoryFilename();
+  QString browserDirectoryFilename = settings.getBrowserExecutable();
 
   /* Set TZ=UTC (to stop leaking timezone information) and
    * MOZ_NO_REMOTE=1 (to allow multiple instances of Firefox */
@@ -657,7 +657,7 @@
 #if defined(Q_OS_WIN)
 
   VidaliaSettings settings;
-  QString browserDirectoryFilename = settings.getBrowserDirectoryFilename();
+  QString browserDirectoryFilename = settings.getBrowserExecutable();
 
   /* Get list of running processes */
   QHash<qint64, QString> procList = win32_process_list();