summaryrefslogtreecommitdiffstats
path: root/base/linux_util.h
diff options
context:
space:
mode:
authorevan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-07-23 22:10:53 +0000
committerevan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-07-23 22:10:53 +0000
commitd6cb85b66439333ea65dfb26d745c8c8d0049aac (patch)
treeca34fec53150c2dd63e023c2c33ff22a6fd83119 /base/linux_util.h
parenteeba96cee2c36a2808dcfd0589382524dc3992ad (diff)
downloadchromium_src-d6cb85b66439333ea65dfb26d745c8c8d0049aac.zip
chromium_src-d6cb85b66439333ea65dfb26d745c8c8d0049aac.tar.gz
chromium_src-d6cb85b66439333ea65dfb26d745c8c8d0049aac.tar.bz2
linux: generalize desktop environment guessing to encompass KDE
BUG=17363 Review URL: http://codereview.chromium.org/159297 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@21455 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/linux_util.h')
-rw-r--r--base/linux_util.h16
1 files changed, 11 insertions, 5 deletions
diff --git a/base/linux_util.h b/base/linux_util.h
index 5a46481..693377c 100644
--- a/base/linux_util.h
+++ b/base/linux_util.h
@@ -32,11 +32,17 @@ class EnvironmentVariableGetter {
static EnvironmentVariableGetter* Create();
};
-// Return true if we appear to be running under Gnome and should attempt to use
-// some prefrences from the desktop environment (eg proxy settings),
-// If someone adds support for other environments, this function could be
-// replaced with one that returns an enum so we an specify Gnome, KDE, etc.
-bool UseGnomeForSettings(EnvironmentVariableGetter* env_var_getter);
+enum DesktopEnvironment {
+ DESKTOP_ENVIRONMENT_OTHER,
+ DESKTOP_ENVIRONMENT_GNOME,
+ DESKTOP_ENVIRONMENT_KDE,
+};
+
+// Return an entry from the DesktopEnvironment enum with a best guess
+// of which desktop environment we're using. We use this to know when
+// to attempt to use preferences from the desktop environment --
+// proxy settings, password manager, etc.
+DesktopEnvironment GetDesktopEnvironment(EnvironmentVariableGetter* env);
} // namespace base