summaryrefslogtreecommitdiffstats
path: root/base/string_util_icu.cc
diff options
context:
space:
mode:
authordeanm@chromium.org <deanm@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-07-13 16:14:42 +0000
committerdeanm@chromium.org <deanm@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-07-13 16:14:42 +0000
commit1d5980af2fbdc5820784d7eb01755940838d0e10 (patch)
tree8300c67d0e6edb9789bb9a7552239f7a0c675e3d /base/string_util_icu.cc
parent1947868ed7d749fb6ee2895ce9e9e5af9d11a085 (diff)
downloadchromium_src-1d5980af2fbdc5820784d7eb01755940838d0e10.zip
chromium_src-1d5980af2fbdc5820784d7eb01755940838d0e10.tar.gz
chromium_src-1d5980af2fbdc5820784d7eb01755940838d0e10.tar.bz2
Move TrimWhitespaceUTF8 from string_util_icu to string_util.
It does not directly use ICU, so this is its proper home. Review URL: http://codereview.chromium.org/155415 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@20492 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/string_util_icu.cc')
-rw-r--r--base/string_util_icu.cc14
1 files changed, 0 insertions, 14 deletions
diff --git a/base/string_util_icu.cc b/base/string_util_icu.cc
index 3bd6f9b..f8a2d99 100644
--- a/base/string_util_icu.cc
+++ b/base/string_util_icu.cc
@@ -674,17 +674,3 @@ std::wstring FormatNumber(int64 number) {
return std::wstring(buffer, static_cast<std::wstring::size_type>(length));
#endif // defined(WCHAR_T_IS_UTF32)
}
-
-TrimPositions TrimWhitespaceUTF8(const std::string& input,
- TrimPositions positions,
- std::string* output) {
- // This implementation is not so fast since it converts the text encoding
- // twice. Please feel free to file a bug if this function hurts the
- // performance of Chrome.
- DCHECK(IsStringUTF8(input));
- std::wstring input_wide = UTF8ToWide(input);
- std::wstring output_wide;
- TrimPositions result = TrimWhitespace(input_wide, positions, &output_wide);
- *output = WideToUTF8(output_wide);
- return result;
-}