Skip to content
Snippets Groups Projects

MB 200: Changes for the system installer

@@ -47,15 +47,13 @@ void ICUUtils::LanguageTagIterForContent::GetNext(nsACString& aBCP47LangTag) {
if (mCurrentFallbackIndex < 2) {
mCurrentFallbackIndex = 2;
// Else take the app's locale:
// Else take the app's locale (or en-US, if spoof English applies):
const bool spoofLocale = nsContentUtils::SpoofLocaleEnglish() &&
!mContent->OwnerDoc()->AllowsL10n();
if (spoofLocale) {
aBCP47LangTag.AssignLiteral("en-US");
return;
}
nsAutoCString appLocale;
LocaleService::GetInstance()->GetAppLocaleAsBCP47(aBCP47LangTag);
return;
Loading