| OLD | NEW |
| 1 // Copyright 2014 PDFium Authors. All rights reserved. | 1 // Copyright 2014 PDFium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com |
| 6 | 6 |
| 7 #ifndef XFA_FGAS_LOCALIZATION_FGAS_LOCALEIMP_H_ | 7 #ifndef XFA_FGAS_LOCALIZATION_FGAS_LOCALEIMP_H_ |
| 8 #define XFA_FGAS_LOCALIZATION_FGAS_LOCALEIMP_H_ | 8 #define XFA_FGAS_LOCALIZATION_FGAS_LOCALEIMP_H_ |
| 9 | 9 |
| 10 #include "xfa/fgas/localization/fgas_locale.h" | 10 #include "xfa/fgas/localization/fgas_locale.h" |
| 11 | 11 |
| 12 class CFX_LCNumeric; | 12 class CFX_LCNumeric; |
| 13 | 13 |
| 14 class CFX_Locale : public IFX_Locale { | |
| 15 public: | |
| 16 CFX_Locale(CXML_Element* pLocaleData); | |
| 17 virtual void Release() { delete this; } | |
| 18 | |
| 19 virtual CFX_WideString GetName(); | |
| 20 virtual void GetNumbericSymbol(FX_LOCALENUMSYMBOL eType, | |
| 21 CFX_WideString& wsNumSymbol) const; | |
| 22 | |
| 23 virtual void GetDateTimeSymbols(CFX_WideString& wsDtSymbol) const; | |
| 24 virtual void GetMonthName(int32_t nMonth, | |
| 25 CFX_WideString& wsMonthName, | |
| 26 FX_BOOL bAbbr = TRUE) const; | |
| 27 virtual void GetDayName(int32_t nWeek, | |
| 28 CFX_WideString& wsDayName, | |
| 29 FX_BOOL bAbbr = TRUE) const; | |
| 30 virtual void GetMeridiemName(CFX_WideString& wsMeridiemName, | |
| 31 FX_BOOL bAM = TRUE) const; | |
| 32 virtual void GetTimeZone(FX_TIMEZONE& tz) const; | |
| 33 virtual void GetEraName(CFX_WideString& wsEraName, FX_BOOL bAD = TRUE) const; | |
| 34 | |
| 35 virtual void GetDatePattern(FX_LOCALEDATETIMESUBCATEGORY eType, | |
| 36 CFX_WideString& wsPattern) const; | |
| 37 virtual void GetTimePattern(FX_LOCALEDATETIMESUBCATEGORY eType, | |
| 38 CFX_WideString& wsPattern) const; | |
| 39 virtual void GetNumPattern(FX_LOCALENUMSUBCATEGORY eType, | |
| 40 CFX_WideString& wsPattern) const; | |
| 41 | |
| 42 protected: | |
| 43 virtual ~CFX_Locale(); | |
| 44 CXML_Element* m_pElement; | |
| 45 }; | |
| 46 | |
| 47 class CFX_FormatString { | 14 class CFX_FormatString { |
| 48 public: | 15 public: |
| 49 CFX_FormatString(IFX_LocaleMgr* pLocaleMgr, FX_BOOL bUseLCID); | 16 CFX_FormatString(IFX_LocaleMgr* pLocaleMgr, FX_BOOL bUseLCID); |
| 50 | 17 |
| 51 void Release() { delete this; } | 18 void Release() { delete this; } |
| 52 | 19 |
| 53 void SplitFormatString(const CFX_WideString& wsFormatString, | 20 void SplitFormatString(const CFX_WideString& wsFormatString, |
| 54 CFX_WideStringArray& wsPatterns); | 21 CFX_WideStringArray& wsPatterns); |
| 55 FX_LOCALECATEGORY GetCategory(const CFX_WideString& wsPattern); | 22 FX_LOCALECATEGORY GetCategory(const CFX_WideString& wsPattern); |
| 56 uint16_t GetLCID(const CFX_WideString& wsPattern); | 23 uint16_t GetLCID(const CFX_WideString& wsPattern); |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 114 IFX_Locale*& pLocale, | 81 IFX_Locale*& pLocale, |
| 115 CFX_WideString& wsDatePattern, | 82 CFX_WideString& wsDatePattern, |
| 116 CFX_WideString& wsTimePattern); | 83 CFX_WideString& wsTimePattern); |
| 117 IFX_Locale* GetPatternLocale(const CFX_WideString& wsLocale); | 84 IFX_Locale* GetPatternLocale(const CFX_WideString& wsLocale); |
| 118 | 85 |
| 119 IFX_LocaleMgr* m_pLocaleMgr; | 86 IFX_LocaleMgr* m_pLocaleMgr; |
| 120 FX_BOOL m_bUseLCID; | 87 FX_BOOL m_bUseLCID; |
| 121 }; | 88 }; |
| 122 | 89 |
| 123 #endif // XFA_FGAS_LOCALIZATION_FGAS_LOCALEIMP_H_ | 90 #endif // XFA_FGAS_LOCALIZATION_FGAS_LOCALEIMP_H_ |
| OLD | NEW |