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

Unified Diff: chromecast/browser/cast_http_user_agent_settings.cc

Issue 2406203002: Use BCP47 compliant format for locale representation (Closed)
Patch Set: add more explanations about why Locale.getLanguage/toLanguageTag is not used Created 4 years, 2 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
Index: chromecast/browser/cast_http_user_agent_settings.cc
diff --git a/chromecast/browser/cast_http_user_agent_settings.cc b/chromecast/browser/cast_http_user_agent_settings.cc
index fcce6bafc5320b4f33082ce231ca5c6756eb2e52..1c91836ce87819e3a38fc30165f29ad62b492d7c 100644
--- a/chromecast/browser/cast_http_user_agent_settings.cc
+++ b/chromecast/browser/cast_http_user_agent_settings.cc
@@ -33,11 +33,11 @@ std::string CastHttpUserAgentSettings::GetAcceptLanguage() const {
std::string new_locale(
#if defined(OS_ANDROID)
// TODO(byungchul): Use transient locale set when new app starts.
- base::android::GetDefaultLocale()
+ base::android::GetDefaultLocaleString()
#else
base::i18n::GetConfiguredLocale()
#endif
- );
+ );
ksk1 2016/10/19 07:21:06 Revert?
Yirui Huang 2016/10/19 07:51:19 I renamed the function name getDefaultLocale in Lo
ksk1 2016/10/19 07:59:53 I understand the method renaming, but you inserted
Yirui Huang 2016/10/19 08:41:46 No, that should be reverted. Thanks.
if (new_locale != last_locale_ || accept_language_.empty()) {
last_locale_ = new_locale;
accept_language_ = net::HttpUtil::GenerateAcceptLanguageHeader(

Powered by Google App Engine
This is Rietveld 408576698