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

Unified Diff: pkg/intl/lib/intl_browser.dart

Issue 11016017: Finding locale from browser needs to canonicalize the result (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 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
« no previous file with comments | « no previous file | pkg/pkg.status » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/intl/lib/intl_browser.dart
===================================================================
--- pkg/intl/lib/intl_browser.dart (revision 13132)
+++ pkg/intl/lib/intl_browser.dart (working copy)
@@ -25,6 +25,6 @@
* [Intl.systemLocale] variable.
*/
Future<String> findSystemLocale() {
- Intl.systemLocale = window.navigator.language.replaceFirst("-","_");
+ Intl.systemLocale = Intl.canonicalizedLocale(window.navigator.language);
return new Future.immediate(Intl.systemLocale);
}
« no previous file with comments | « no previous file | pkg/pkg.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698