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

Side by Side Diff: chrome/common/l10n_util.h

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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/common/common.scons ('k') | chrome/common/l10n_util.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // This file contains utility functions for dealing with localized 5 // This file contains utility functions for dealing with localized
6 // content. 6 // content.
7 7
8 #ifndef CHROME_COMMON_L10N_UTIL_H_ 8 #ifndef CHROME_COMMON_L10N_UTIL_H_
9 #define CHROME_COMMON_L10N_UTIL_H_ 9 #define CHROME_COMMON_L10N_UTIL_H_
10 10
(...skipping 30 matching lines...) Expand all
41 // nearly all cases you shouldn't call this, rather use GetApplicationLocale 41 // nearly all cases you shouldn't call this, rather use GetApplicationLocale
42 // defined on browser_process. 42 // defined on browser_process.
43 // 43 //
44 // Returns the locale used by the Application. First we use the value from the 44 // Returns the locale used by the Application. First we use the value from the
45 // command line (--lang), second we try the value in the prefs file (passed in 45 // command line (--lang), second we try the value in the prefs file (passed in
46 // as |pref_locale|), finally, we fall back on the system locale. We only return 46 // as |pref_locale|), finally, we fall back on the system locale. We only return
47 // a value if there's a corresponding resource DLL for the locale. Otherwise, 47 // a value if there's a corresponding resource DLL for the locale. Otherwise,
48 // we fall back to en-us. 48 // we fall back to en-us.
49 std::wstring GetApplicationLocale(const std::wstring& pref_locale); 49 std::wstring GetApplicationLocale(const std::wstring& pref_locale);
50 50
51 // Given a locale code, return true if the OS is capable of supporting it.
52 // For instance, Oriya is not well supported on Windows XP and we return
53 // false for "or".
54 bool IsLocaleSupportedByOS(const std::wstring& locale);
55
51 // This method returns the Local Name of the Locale Code. For example, for 56 // This method returns the Local Name of the Locale Code. For example, for
52 // |local_code_wstr| = "en-US", it returns "English (United States)". 57 // |local_code_wstr| = "en-US", it returns "English (United States)".
53 // |app_locale_wstr| can be obtained in the UI thread - for example: 58 // |app_locale_wstr| can be obtained in the UI thread - for example:
54 // const std::wstring app_locale_wstr = g_browser_process-> 59 // const std::wstring app_locale_wstr = g_browser_process->
55 // GetApplicationLocale(); 60 // GetApplicationLocale();
56 // If |is_for_ui| is true, U+200F is appended so that it can be 61 // If |is_for_ui| is true, U+200F is appended so that it can be
57 // rendered properly in a RTL Chrome. 62 // rendered properly in a RTL Chrome.
58 std::wstring GetLocalName(const std::string& locale_code_str, 63 std::wstring GetLocalName(const std::string& locale_code_str,
59 const std::wstring& app_locale_wstr, 64 const std::wstring& app_locale_wstr,
60 bool is_for_ui); 65 bool is_for_ui);
(...skipping 285 matching lines...) Expand 10 before | Expand all | Expand 10 after
346 351
347 private: 352 private:
348 UBiDi* bidi_; 353 UBiDi* bidi_;
349 354
350 DISALLOW_COPY_AND_ASSIGN(BiDiLineIterator); 355 DISALLOW_COPY_AND_ASSIGN(BiDiLineIterator);
351 }; 356 };
352 357
353 } 358 }
354 359
355 #endif // CHROME_COMMON_L10N_UTIL_H_ 360 #endif // CHROME_COMMON_L10N_UTIL_H_
OLDNEW
« no previous file with comments | « chrome/common/common.scons ('k') | chrome/common/l10n_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698