| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 42 | 42 |
| 43 namespace blink { | 43 namespace blink { |
| 44 | 44 |
| 45 // We should use this class only for LocalizedNumberICU.cpp, LocalizedDateICU.cp
p, | 45 // We should use this class only for LocalizedNumberICU.cpp, LocalizedDateICU.cp
p, |
| 46 // and LocalizedNumberICUTest.cpp. | 46 // and LocalizedNumberICUTest.cpp. |
| 47 class PLATFORM_EXPORT LocaleICU : public Locale { | 47 class PLATFORM_EXPORT LocaleICU : public Locale { |
| 48 public: | 48 public: |
| 49 static PassOwnPtr<LocaleICU> create(const char* localeString); | 49 static PassOwnPtr<LocaleICU> create(const char* localeString); |
| 50 virtual ~LocaleICU(); | 50 virtual ~LocaleICU(); |
| 51 | 51 |
| 52 virtual const Vector<String>& weekDayShortLabels() OVERRIDE; | 52 virtual const Vector<String>& weekDayShortLabels() override; |
| 53 virtual unsigned firstDayOfWeek() OVERRIDE; | 53 virtual unsigned firstDayOfWeek() override; |
| 54 virtual bool isRTL() OVERRIDE; | 54 virtual bool isRTL() override; |
| 55 virtual String dateFormat() OVERRIDE; | 55 virtual String dateFormat() override; |
| 56 virtual String monthFormat() OVERRIDE; | 56 virtual String monthFormat() override; |
| 57 virtual String shortMonthFormat() OVERRIDE; | 57 virtual String shortMonthFormat() override; |
| 58 virtual String timeFormat() OVERRIDE; | 58 virtual String timeFormat() override; |
| 59 virtual String shortTimeFormat() OVERRIDE; | 59 virtual String shortTimeFormat() override; |
| 60 virtual String dateTimeFormatWithSeconds() OVERRIDE; | 60 virtual String dateTimeFormatWithSeconds() override; |
| 61 virtual String dateTimeFormatWithoutSeconds() OVERRIDE; | 61 virtual String dateTimeFormatWithoutSeconds() override; |
| 62 virtual const Vector<String>& monthLabels() OVERRIDE; | 62 virtual const Vector<String>& monthLabels() override; |
| 63 virtual const Vector<String>& shortMonthLabels() OVERRIDE; | 63 virtual const Vector<String>& shortMonthLabels() override; |
| 64 virtual const Vector<String>& standAloneMonthLabels() OVERRIDE; | 64 virtual const Vector<String>& standAloneMonthLabels() override; |
| 65 virtual const Vector<String>& shortStandAloneMonthLabels() OVERRIDE; | 65 virtual const Vector<String>& shortStandAloneMonthLabels() override; |
| 66 virtual const Vector<String>& timeAMPMLabels() OVERRIDE; | 66 virtual const Vector<String>& timeAMPMLabels() override; |
| 67 | 67 |
| 68 private: | 68 private: |
| 69 explicit LocaleICU(const char*); | 69 explicit LocaleICU(const char*); |
| 70 String decimalSymbol(UNumberFormatSymbol); | 70 String decimalSymbol(UNumberFormatSymbol); |
| 71 String decimalTextAttribute(UNumberFormatTextAttribute); | 71 String decimalTextAttribute(UNumberFormatTextAttribute); |
| 72 virtual void initializeLocaleData() OVERRIDE; | 72 virtual void initializeLocaleData() override; |
| 73 | 73 |
| 74 bool detectSignAndGetDigitRange(const String& input, bool& isNegative, unsig
ned& startIndex, unsigned& endIndex); | 74 bool detectSignAndGetDigitRange(const String& input, bool& isNegative, unsig
ned& startIndex, unsigned& endIndex); |
| 75 unsigned matchedDecimalSymbolIndex(const String& input, unsigned& position); | 75 unsigned matchedDecimalSymbolIndex(const String& input, unsigned& position); |
| 76 | 76 |
| 77 bool initializeShortDateFormat(); | 77 bool initializeShortDateFormat(); |
| 78 UDateFormat* openDateFormat(UDateFormatStyle timeStyle, UDateFormatStyle dat
eStyle) const; | 78 UDateFormat* openDateFormat(UDateFormatStyle timeStyle, UDateFormatStyle dat
eStyle) const; |
| 79 | 79 |
| 80 void initializeCalendar(); | 80 void initializeCalendar(); |
| 81 | 81 |
| 82 PassOwnPtr<Vector<String> > createLabelVector(const UDateFormat*, UDateForma
tSymbolType, int32_t startIndex, int32_t size); | 82 PassOwnPtr<Vector<String> > createLabelVector(const UDateFormat*, UDateForma
tSymbolType, int32_t startIndex, int32_t size); |
| (...skipping 19 matching lines...) Expand all Loading... |
| 102 UDateFormat* m_shortTimeFormat; | 102 UDateFormat* m_shortTimeFormat; |
| 103 Vector<String> m_shortMonthLabels; | 103 Vector<String> m_shortMonthLabels; |
| 104 Vector<String> m_standAloneMonthLabels; | 104 Vector<String> m_standAloneMonthLabels; |
| 105 Vector<String> m_shortStandAloneMonthLabels; | 105 Vector<String> m_shortStandAloneMonthLabels; |
| 106 Vector<String> m_timeAMPMLabels; | 106 Vector<String> m_timeAMPMLabels; |
| 107 bool m_didCreateTimeFormat; | 107 bool m_didCreateTimeFormat; |
| 108 }; | 108 }; |
| 109 | 109 |
| 110 } // namespace blink | 110 } // namespace blink |
| 111 #endif | 111 #endif |
| OLD | NEW |