-
tkent@chromium.org authored
https://bugs.webkit.org/show_bug.cgi?id=98117 Reviewed by Kentaro Hara. Source/WebCore: http://trac.webkit.org/changeset/130127 introduced Localizer::dateFormat, and this is its implementation for LocaleICU classs. The code is going to be used when ENABLE_INPUT_MULTIPLE_FIELDS_UI is enabled. Tests: Added a new test to WebKit/chromium/tests/LocaleWinTest.cpp. * platform/text/LocaleWin.cpp: (WebCore::parseDateFormat): Fix a continuous apostrophes parsing bug; "abc''''def" produced "abc'''def" (WebCore::appendAsLDMLLiteral): A helper function to make a literal string for LDML. (WebCore::convertWindowsDateFormatToLDML): Creates an LDML format from a parsed date format tokens. (WebCore::LocaleWin::dateFormat): Implemented. This uses convertWindowsDateFormatToLDML. (WebCore::LocaleWin::dateFormat): Added for testing. The source windows format is specified as a function argument. * platform/text/LocaleWin.h: (LocaleWin): Declare m_dateFormat and dateFormat(). Source/WebKit/chromium: * tests/LocaleWinTest.cpp: (TEST_F): Add tests for LocaleWin::dateFormat. git-svn-id: http://svn.webkit.org/repository/webkit/trunk@130242 268f45cc-cd09-0410-ab3c-d52691b4dbfc
c934c4b0