summaryrefslogtreecommitdiffstats
path: root/app
diff options
context:
space:
mode:
authoroshima@chromium.org <oshima@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-03-25 00:48:49 +0000
committeroshima@chromium.org <oshima@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-03-25 00:48:49 +0000
commit31627d5823b7ee0d589f4a5c4a9ad4ec44917356 (patch)
tree492c826af74378fbc04293e936b30b8161e65ccb /app
parent64196b62bbf6fc221e283a008d8844a979ea13bd (diff)
downloadchromium_src-31627d5823b7ee0d589f4a5c4a9ad4ec44917356.zip
chromium_src-31627d5823b7ee0d589f4a5c4a9ad4ec44917356.tar.gz
chromium_src-31627d5823b7ee0d589f4a5c4a9ad4ec44917356.tar.bz2
Enable LAGNUAGE environment for chromeos in debug build.
This is still useful when debugging/troubleshooting. BUG=none TEST=build debug build with GYP_DEFINES=chromeos=1 and run "$ LAGNAUGE=he ./out/Debug/chrome". Review URL: http://codereview.chromium.org/1139005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@42566 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'app')
-rw-r--r--app/l10n_util.cc9
1 files changed, 8 insertions, 1 deletions
diff --git a/app/l10n_util.cc b/app/l10n_util.cc
index b22e26f..d4eeed1 100644
--- a/app/l10n_util.cc
+++ b/app/l10n_util.cc
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved.
+// Copyright (c) 2010 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -395,6 +395,13 @@ std::string GetApplicationLocale(const std::wstring& pref_locale) {
candidates.push_back(system_locale);
#elif defined(OS_CHROMEOS)
+ // We use --lang on chroemos for debugging/troubleshooting purpose.
+ const CommandLine& parsed_command_line = *CommandLine::ForCurrentProcess();
+ const std::string& lang_arg =
+ parsed_command_line.GetSwitchValueASCII(switches::kLang);
+ if (!lang_arg.empty())
+ candidates.push_back(lang_arg);
+
// On ChromeOS, try user prefs. This restores the locale used by the
// previous run of the OS.
if (!pref_locale.empty())