| Index: chrome/browser/search/hotword_service.cc
|
| diff --git a/chrome/browser/search/hotword_service.cc b/chrome/browser/search/hotword_service.cc
|
| index 2f75b0394f5b73731f80cbde6ea0afd001deb541..8c63fc3632c83d34395bb3e842246064f3002f4c 100644
|
| --- a/chrome/browser/search/hotword_service.cc
|
| +++ b/chrome/browser/search/hotword_service.cc
|
| @@ -142,14 +142,15 @@ ExtensionService* GetExtensionService(Profile* profile) {
|
| }
|
|
|
| std::string GetCurrentLocale(Profile* profile) {
|
| - std::string locale =
|
| #if defined(OS_CHROMEOS)
|
| - // On ChromeOS locale is per-profile.
|
| + std::string profile_locale =
|
| profile->GetPrefs()->GetString(prefs::kApplicationLocale);
|
| -#else
|
| - g_browser_process->GetApplicationLocale();
|
| + if (!profile_locale.empty()) {
|
| + // On ChromeOS locale is per-profile, but only if set.
|
| + return profile_locale;
|
| + }
|
| #endif
|
| - return locale;
|
| + return g_browser_process->GetApplicationLocale();
|
| }
|
|
|
| } // namespace
|
|
|