Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1362)

Unified Diff: base/xdg_util.cc

Issue 3029062: base: rename Environment::GetEnv to Environment::GetVar. (Closed) Base URL: git://git.chromium.org/chromium.git
Patch Set: Created 10 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « base/environment_unittest.cc ('k') | base/xdg_util_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/xdg_util.cc
diff --git a/base/xdg_util.cc b/base/xdg_util.cc
index 69789869160c98a4155a6b0f5f51e406495593bc..017ae7abd0444b4bf7be293084ae5759c2471b64 100644
--- a/base/xdg_util.cc
+++ b/base/xdg_util.cc
@@ -14,7 +14,7 @@ namespace base {
FilePath GetXDGDirectory(Environment* env, const char* env_name,
const char* fallback_dir) {
std::string env_value;
- if (env->GetEnv(env_name, &env_value) && !env_value.empty())
+ if (env->GetVar(env_name, &env_value) && !env_value.empty())
return FilePath(env_value);
return file_util::GetHomeDir().Append(fallback_dir);
}
@@ -32,7 +32,7 @@ FilePath GetXDGUserDirectory(Environment* env, const char* dir_name,
DesktopEnvironment GetDesktopEnvironment(Environment* env) {
std::string desktop_session;
- if (env->GetEnv("DESKTOP_SESSION", &desktop_session)) {
+ if (env->GetVar("DESKTOP_SESSION", &desktop_session)) {
if (desktop_session == "gnome") {
return DESKTOP_ENVIRONMENT_GNOME;
} else if (desktop_session == "kde4") {
« no previous file with comments | « base/environment_unittest.cc ('k') | base/xdg_util_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698