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

Unified Diff: chrome/common/l10n_util.cc

Issue 45054: Block Oriya locale on Windows XP.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 9 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 | « chrome/common/l10n_util.h ('k') | chrome/common/l10n_util_posix.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/l10n_util.cc
===================================================================
--- chrome/common/l10n_util.cc (revision 12453)
+++ chrome/common/l10n_util.cc (working copy)
@@ -128,6 +128,9 @@
if (test_locale != locale)
return false;
+ if (!l10n_util::IsLocaleSupportedByOS(locale))
+ return false;
+
FilePath test_path = FilePath::FromWStringHack(locale_path)
.Append(FilePath::FromWStringHack(locale))
.ReplaceExtension(kLocaleFileExtension);
@@ -665,6 +668,8 @@
// Filter out the names that have aliases.
if (IsDuplicateName(locale_name))
continue;
+ if (!IsLocaleSupportedByOS(ASCIIToWide(locale_name)))
+ continue;
// Normalize underscores to hyphens because that's what our locale files
// use.
std::replace(locale_name.begin(), locale_name.end(), '_', '-');
« no previous file with comments | « chrome/common/l10n_util.h ('k') | chrome/common/l10n_util_posix.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698