PagePopupController.formatMonth should support short month format
authorkeishi@webkit.org <keishi@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 15 Feb 2013 14:05:04 +0000 (14:05 +0000)
committerkeishi@webkit.org <keishi@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 15 Feb 2013 14:05:04 +0000 (14:05 +0000)
commit51c105ff73e41363a94649d9294daa7449a4c038
treefe0619034a37f65714591181b340d79b7c46fb70
parent56407ae913a137e0f3715043c38ecb594699a5f0
PagePopupController.formatMonth should support short month format
https://bugs.webkit.org/show_bug.cgi?id=109530

Reviewed by Kent Tamura.

Source/WebCore:

PagePopupController.formatMonth should support short month format so we
can use it in the new calendar picker.

Tested by LocaleMacTest::formatMonth.

* page/PagePopupController.cpp:
(WebCore::PagePopupController::formatMonth): Take an extra bool argument to switch to short month format.
* page/PagePopupController.h:
(PagePopupController):
* page/PagePopupController.idl:
* platform/text/LocaleICU.cpp:
(WebCore::LocaleICU::shortMonthFormat):
(WebCore):
* platform/text/LocaleICU.h:
(LocaleICU):
* platform/text/LocaleNone.cpp:
(WebCore::shortMonthFormat):
(WebCore):
* platform/text/PlatformLocale.cpp:
(WebCore::DateTimeStringBuilder::visitField):
(WebCore::Locale::formatDateTime):
* platform/text/PlatformLocale.h:
(Locale):
* platform/text/mac/LocaleMac.h:
(LocaleMac):
* platform/text/mac/LocaleMac.mm:
(WebCore::LocaleMac::shortMonthFormat):
(WebCore):
* platform/text/win/LocaleWin.cpp:
(WebCore::LocaleWin::shortMonthFormat): Windows doesn't have a short
month format so we just replace MMMM with MMM.
(WebCore):
* platform/text/win/LocaleWin.h:
(LocaleWin):

Source/WebKit/chromium:

* tests/LocaleMacTest.cpp:
(LocaleMacTest::formatMonth):
(TEST_F):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@142988 268f45cc-cd09-0410-ab3c-d52691b4dbfc
15 files changed:
Source/WebCore/ChangeLog
Source/WebCore/page/PagePopupController.cpp
Source/WebCore/page/PagePopupController.h
Source/WebCore/page/PagePopupController.idl
Source/WebCore/platform/text/LocaleICU.cpp
Source/WebCore/platform/text/LocaleICU.h
Source/WebCore/platform/text/LocaleNone.cpp
Source/WebCore/platform/text/PlatformLocale.cpp
Source/WebCore/platform/text/PlatformLocale.h
Source/WebCore/platform/text/mac/LocaleMac.h
Source/WebCore/platform/text/mac/LocaleMac.mm
Source/WebCore/platform/text/win/LocaleWin.cpp
Source/WebCore/platform/text/win/LocaleWin.h
Source/WebKit/chromium/ChangeLog
Source/WebKit/chromium/tests/LocaleMacTest.cpp