RESOLVED FIXED 99787
Add shortMonthLabels and shortStandAloneMonthLabels to Localizer
https://bugs.webkit.org/show_bug.cgi?id=99787
Summary Add shortMonthLabels and shortStandAloneMonthLabels to Localizer
Kent Tamura
Reported 2012-10-18 18:15:11 PDT
because Localizer::monthFormat can contain MMM or LLL. See http://www.unicode.org/reports/tr35/#Date_Format_Patterns
Attachments
Patch (18.90 KB, patch)
2012-10-18 21:40 PDT, Kent Tamura
haraken: review+
Kent Tamura
Comment 1 2012-10-18 21:40:25 PDT
Kentaro Hara
Comment 2 2012-10-18 21:55:04 PDT
Comment on attachment 169544 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=169544&action=review > Source/WebCore/platform/text/LocaleICU.cpp:466 > + m_shortStandAloneMonthLabels = *labels; Nit: I would prefer early return here. 'return m_shortStandAloneMonthLabels;' > Source/WebCore/platform/text/LocaleICU.cpp:468 > + if (m_shortStandAloneMonthLabels.isEmpty()) Then you can remove this branch. > Source/WebCore/platform/text/LocaleNone.cpp:99 > + m_shortMonthLabels.reserveCapacity(12); Nit: 12 => WTF_ARRAY_LENGTH(WTF::monthName)
Kent Tamura
Comment 3 2012-10-18 22:05:15 PDT
Comment on attachment 169544 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=169544&action=review >> Source/WebCore/platform/text/LocaleICU.cpp:466 >> + m_shortStandAloneMonthLabels = *labels; > > Nit: I would prefer early return here. 'return m_shortStandAloneMonthLabels;' Done. >> Source/WebCore/platform/text/LocaleNone.cpp:99 >> + m_shortMonthLabels.reserveCapacity(12); > > Nit: 12 => WTF_ARRAY_LENGTH(WTF::monthName) Done.
Kent Tamura
Comment 4 2012-10-18 22:08:53 PDT
Note You need to log in before you can comment on or make changes to this bug.