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

Unified Diff: ui/base/l10n/l10n_util.h

Issue 23591040: Use ICU for string pluralization in the extension permission dialog. (Closed) Base URL: http://git.chromium.org/chromium/src.git@gtk-extension-install-dialog
Patch Set: Created 7 years, 3 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/extensions/permissions/permissions_data_unittest.cc ('k') | ui/base/l10n/l10n_util.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/base/l10n/l10n_util.h
diff --git a/ui/base/l10n/l10n_util.h b/ui/base/l10n/l10n_util.h
index 7c26b80346714764111bdb1039333808b662eec3..d7753365d003a896aa03bc504132c53f09afeadc 100644
--- a/ui/base/l10n/l10n_util.h
+++ b/ui/base/l10n/l10n_util.h
@@ -139,6 +139,14 @@ UI_EXPORT string16 GetStringFUTF16(int message_id,
UI_EXPORT string16 GetStringFUTF16Int(int message_id, int a);
string16 GetStringFUTF16Int(int message_id, int64 a);
+// Get a resource string using |number| to decide which of |message_ids| should
+// be used. |message_ids| must be size 6 and in order: default, singular, zero,
+// two, few, many.
+UI_EXPORT string16 GetPluralStringFUTF16(const std::vector<int>& message_ids,
+ int number);
+UI_EXPORT std::string GetPluralStringFUTF8(const std::vector<int>& message_ids,
+ int number);
+
// In place sorting of string16 strings using collation rules for |locale|.
UI_EXPORT void SortStrings16(const std::string& locale,
std::vector<string16>* strings);
« no previous file with comments | « chrome/common/extensions/permissions/permissions_data_unittest.cc ('k') | ui/base/l10n/l10n_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698