summaryrefslogtreecommitdiffstats
path: root/webkit/glue
diff options
context:
space:
mode:
authordarin@chromium.org <darin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-20 06:39:16 +0000
committerdarin@chromium.org <darin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-20 06:39:16 +0000
commit243dc40e3f8110e5afe0aae7a7572518037cbb68 (patch)
treebe29f76fe9674b79c37c8327271a3a1577ebd26b /webkit/glue
parentff6456c561bc99141ff06384c8c3fbd45162a628 (diff)
downloadchromium_src-243dc40e3f8110e5afe0aae7a7572518037cbb68.zip
chromium_src-243dc40e3f8110e5afe0aae7a7572518037cbb68.tar.gz
chromium_src-243dc40e3f8110e5afe0aae7a7572518037cbb68.tar.bz2
Add a UI string for multiple file selection for <input type=file multiple>.
WebCore::multipleFileUploadText() is already declared in LocalizeStrings.h, and implemented and used in other platforms. This patch won't change Chromium's behavior for now. We need to change WebCore/platform/chromium/FileChooserChromium.cpp to use this string. Patch by Kent Tamura (tkent@google.com) R=darin BUG=8740 Review URL: http://codereview.chromium.org/113620 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16468 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/glue')
-rw-r--r--webkit/glue/localized_strings.cc6
-rw-r--r--webkit/glue/webkit_strings.grd3
2 files changed, 9 insertions, 0 deletions
diff --git a/webkit/glue/localized_strings.cc b/webkit/glue/localized_strings.cc
index 2df1b8c..38c7b84 100644
--- a/webkit/glue/localized_strings.cc
+++ b/webkit/glue/localized_strings.cc
@@ -118,6 +118,12 @@ String WebCore::AXLinkActionVerb() {
return GetLocalizedString(IDS_AX_LINK_ACTION_VERB);
}
+String WebCore::multipleFileUploadText(unsigned number_of_files) {
+ return webkit_glue::String16ToString(ReplaceStringPlaceholders(
+ webkit_glue::GetLocalizedString(IDS_FORM_FILE_MULTIPLE_UPLOAD),
+ WideToUTF16Hack(UintToWString(number_of_files)),
+ NULL));
+}
// Used in FTPDirectoryDocument.cpp
String WebCore::unknownFileSizeText() {
return String();
diff --git a/webkit/glue/webkit_strings.grd b/webkit/glue/webkit_strings.grd
index f2e7a36a..c126c4c 100644
--- a/webkit/glue/webkit_strings.grd
+++ b/webkit/glue/webkit_strings.grd
@@ -230,6 +230,9 @@ below:
<message name="IDS_FORM_FILE_NO_FILE_DRAG_LABEL" desc="text to display in file button used in HTML forms when no file is selected to indicate that files can be dragged onto the file button">
Drag file here
</message>
+ <message name="IDS_FORM_FILE_MULTIPLE_UPLOAD" desc="text to display next to file buttons in HTML forms when 2 or more files are selected for uploading. This is not used for a case that just 1 file is selected.">
+ <ph name="NUMBER_OF_FILES">$1<ex>3</ex></ph> files
+ </message>
<message name="IDS_RECENT_SEARCHES_NONE" desc="Label for only item in menu that appears when clicking on the search field image, when no searches have been performed">
No recent searches