summaryrefslogtreecommitdiff
path: root/xfa/src/fgas/src
diff options
context:
space:
mode:
Diffstat (limited to 'xfa/src/fgas/src')
-rw-r--r--xfa/src/fgas/src/layout/fx_rtfbreak.cpp1
-rw-r--r--xfa/src/fgas/src/localization/fx_locale.cpp20
-rw-r--r--xfa/src/fgas/src/xml/fx_sax_imp.cpp25
3 files changed, 11 insertions, 35 deletions
diff --git a/xfa/src/fgas/src/layout/fx_rtfbreak.cpp b/xfa/src/fgas/src/layout/fx_rtfbreak.cpp
index 4e1866b8e4..15fa5c3b53 100644
--- a/xfa/src/fgas/src/layout/fx_rtfbreak.cpp
+++ b/xfa/src/fgas/src/layout/fx_rtfbreak.cpp
@@ -1446,7 +1446,6 @@ int32_t CFX_RTFBreak::GetCharRects(FX_LPCRTFTEXTOBJ pText,
rtArray.SetSize(iLength);
FX_DWORD dwStyles = pText->dwLayoutStyles;
FX_BOOL bVertical = (dwStyles & FX_RTFLAYOUTSTYLE_VerticalLayout) != 0;
- FX_BOOL bMBCSCode = (dwStyles & FX_RTFLAYOUTSTYLE_MBCSCode) != 0;
FX_BOOL bSingleLine = (dwStyles & FX_RTFLAYOUTSTYLE_SingleLine) != 0;
FX_BOOL bCombText = (dwStyles & FX_TXTLAYOUTSTYLE_CombText) != 0;
FX_WCHAR wch, wLineBreakChar = pText->wLineBreakChar;
diff --git a/xfa/src/fgas/src/localization/fx_locale.cpp b/xfa/src/fgas/src/localization/fx_locale.cpp
index fc3ba78bd0..1227086bb5 100644
--- a/xfa/src/fgas/src/localization/fx_locale.cpp
+++ b/xfa/src/fgas/src/localization/fx_locale.cpp
@@ -935,8 +935,7 @@ FX_BOOL CFX_FormatString::ParseText(const CFX_WideString& wsSrcText,
return FALSE;
}
CFX_WideString wsTextFormat;
- IFX_Locale* pLocale =
- GetTextFormat(wsPattern, FX_WSTRC(L"text"), wsTextFormat);
+ GetTextFormat(wsPattern, FX_WSTRC(L"text"), wsTextFormat);
if (wsTextFormat.IsEmpty()) {
return FALSE;
}
@@ -1018,7 +1017,6 @@ FX_BOOL CFX_FormatString::ParseNum(const CFX_WideString& wsSrcNum,
int32_t iExponent = 0;
CFX_WideString wsDotSymbol;
pLocale->GetNumbericSymbol(FX_LOCALENUMSYMBOL_Decimal, wsDotSymbol);
- int32_t iDotLen = wsDotSymbol.GetLength();
CFX_WideString wsGroupSymbol;
pLocale->GetNumbericSymbol(FX_LOCALENUMSYMBOL_Grouping, wsGroupSymbol);
int32_t iGroupLen = wsGroupSymbol.GetLength();
@@ -1785,7 +1783,6 @@ FX_BOOL CFX_FormatString::ParseNum(const CFX_WideString& wsSrcNum,
int32_t iExponent = 0;
CFX_WideString wsDotSymbol;
pLocale->GetNumbericSymbol(FX_LOCALENUMSYMBOL_Decimal, wsDotSymbol);
- int32_t iDotLen = wsDotSymbol.GetLength();
CFX_WideString wsGroupSymbol;
pLocale->GetNumbericSymbol(FX_LOCALENUMSYMBOL_Grouping, wsGroupSymbol);
int32_t iGroupLen = wsGroupSymbol.GetLength();
@@ -2864,8 +2861,7 @@ FX_BOOL CFX_FormatString::ParseDateTime(const CFX_WideString& wsSrcDateTime,
FX_BOOL CFX_FormatString::ParseZero(const CFX_WideString& wsSrcText,
const CFX_WideString& wsPattern) {
CFX_WideString wsTextFormat;
- IFX_Locale* pLocale =
- GetTextFormat(wsPattern, FX_WSTRC(L"zero"), wsTextFormat);
+ GetTextFormat(wsPattern, FX_WSTRC(L"zero"), wsTextFormat);
int32_t iText = 0, iPattern = 0;
const FX_WCHAR* pStrText = (const FX_WCHAR*)wsSrcText;
int32_t iLenText = wsSrcText.GetLength();
@@ -2896,8 +2892,7 @@ FX_BOOL CFX_FormatString::ParseZero(const CFX_WideString& wsSrcText,
FX_BOOL CFX_FormatString::ParseNull(const CFX_WideString& wsSrcText,
const CFX_WideString& wsPattern) {
CFX_WideString wsTextFormat;
- IFX_Locale* pLocale =
- GetTextFormat(wsPattern, FX_WSTRC(L"null"), wsTextFormat);
+ GetTextFormat(wsPattern, FX_WSTRC(L"null"), wsTextFormat);
int32_t iText = 0, iPattern = 0;
const FX_WCHAR* pStrText = (const FX_WCHAR*)wsSrcText;
int32_t iLenText = wsSrcText.GetLength();
@@ -2936,8 +2931,7 @@ FX_BOOL CFX_FormatString::FormatText(const CFX_WideString& wsSrcText,
return FALSE;
}
CFX_WideString wsTextFormat;
- IFX_Locale* pLocale =
- GetTextFormat(wsPattern, FX_WSTRC(L"text"), wsTextFormat);
+ GetTextFormat(wsPattern, FX_WSTRC(L"text"), wsTextFormat);
int32_t iText = 0, iPattern = 0;
const FX_WCHAR* pStrText = (const FX_WCHAR*)wsSrcText;
const FX_WCHAR* pStrPattern = (const FX_WCHAR*)wsTextFormat;
@@ -4441,8 +4435,7 @@ FX_BOOL CFX_FormatString::FormatZero(const CFX_WideString& wsPattern,
return FALSE;
}
CFX_WideString wsTextFormat;
- IFX_Locale* pLocale =
- GetTextFormat(wsPattern, FX_WSTRC(L"zero"), wsTextFormat);
+ GetTextFormat(wsPattern, FX_WSTRC(L"zero"), wsTextFormat);
int32_t iPattern = 0;
const FX_WCHAR* pStrPattern = (const FX_WCHAR*)wsTextFormat;
int32_t iLenPattern = wsTextFormat.GetLength();
@@ -4464,8 +4457,7 @@ FX_BOOL CFX_FormatString::FormatNull(const CFX_WideString& wsPattern,
return FALSE;
}
CFX_WideString wsTextFormat;
- IFX_Locale* pLocale =
- GetTextFormat(wsPattern, FX_WSTRC(L"null"), wsTextFormat);
+ GetTextFormat(wsPattern, FX_WSTRC(L"null"), wsTextFormat);
int32_t iPattern = 0;
const FX_WCHAR* pStrPattern = (const FX_WCHAR*)wsTextFormat;
int32_t iLenPattern = wsTextFormat.GetLength();
diff --git a/xfa/src/fgas/src/xml/fx_sax_imp.cpp b/xfa/src/fgas/src/xml/fx_sax_imp.cpp
index 20d65d3f74..6a4ad34b8c 100644
--- a/xfa/src/fgas/src/xml/fx_sax_imp.cpp
+++ b/xfa/src/fgas/src/xml/fx_sax_imp.cpp
@@ -66,32 +66,17 @@ void CFX_SAXFile::Reset() {
}
m_pFile = NULL;
}
-#define FX_SAXCHARTYPE_Normal 0
-#define FX_SAXCHARTYPE_Space 1
-static uint8_t g_SAX_CharType[256] = {
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
-};
CFX_SAXReader::CFX_SAXReader()
: m_File(),
- m_pHandler(NULL),
+ m_pHandler(nullptr),
m_iState(-1),
- m_pRoot(NULL),
- m_pCurItem(NULL),
+ m_pRoot(nullptr),
+ m_pCurItem(nullptr),
m_dwItemID(0),
m_iDataSize(256),
m_iNameSize(256),
- m_pCommentContext(NULL),
- m_dwParseMode(0) {
+ m_dwParseMode(0),
+ m_pCommentContext(nullptr) {
m_pszData = (uint8_t*)FX_Alloc(uint8_t, m_iDataSize);
m_pszName = (uint8_t*)FX_Alloc(uint8_t, m_iNameSize);
}