Bug 99704 - Add Localizer::monthFormat and implementations
Summary: Add Localizer::monthFormat and implementations
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Platform (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Kent Tamura
URL:
Keywords:
Depends on:
Blocks: 97299 99787
  Show dependency treegraph
 
Reported: 2012-10-18 03:35 PDT by Kent Tamura
Modified: 2012-10-18 18:15 PDT (History)
2 users (show)

See Also:


Attachments
Patch (13.59 KB, patch)
2012-10-18 03:59 PDT, Kent Tamura
haraken: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Kent Tamura 2012-10-18 03:35:08 PDT
Localizer::monthFormat will be used for input[type=month].
Comment 1 Kent Tamura 2012-10-18 03:59:59 PDT
Created attachment 169388 [details]
Patch
Comment 2 Kentaro Hara 2012-10-18 06:43:09 PDT
Comment on attachment 169388 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=169388&action=review

> Source/WebCore/platform/text/LocaleWin.cpp:720
> +    m_monthFormat = convertWindowsDateFormatToLDML(parseDateFormat(getLocaleInfoString(LOCALE_SYEARMONTH)));

(I don't know the details but) don't you need to use m_locale instead of LOCALE_SYEARMONTH?

> Source/WebKit/chromium/tests/LocaleMacTest.cpp:247
> +    EXPECT_STREQ("MMM yyyy", monthFormat("en_US").utf8().data());

Nit: Shall we add a test case for French, just like other tests?
Comment 3 Kent Tamura 2012-10-18 07:29:17 PDT
Comment on attachment 169388 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=169388&action=review

>> Source/WebCore/platform/text/LocaleWin.cpp:720
>> +    m_monthFormat = convertWindowsDateFormatToLDML(parseDateFormat(getLocaleInfoString(LOCALE_SYEARMONTH)));
> 
> (I don't know the details but) don't you need to use m_locale instead of LOCALE_SYEARMONTH?

getLocaleInfoString() refers to m_lcid.

>> Source/WebKit/chromium/tests/LocaleMacTest.cpp:247
>> +    EXPECT_STREQ("MMM yyyy", monthFormat("en_US").utf8().data());
> 
> Nit: Shall we add a test case for French, just like other tests?

will do.
Comment 4 Kent Tamura 2012-10-18 07:32:22 PDT
Committed r131749: <http://trac.webkit.org/changeset/131749>