summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--xfa/fde/css/fde_cssstylesheet.cpp16
-rw-r--r--xfa/fde/css/fde_cssstylesheet.h4
2 files changed, 1 insertions, 19 deletions
diff --git a/xfa/fde/css/fde_cssstylesheet.cpp b/xfa/fde/css/fde_cssstylesheet.cpp
index 4477593359..5bbd9fd49e 100644
--- a/xfa/fde/css/fde_cssstylesheet.cpp
+++ b/xfa/fde/css/fde_cssstylesheet.cpp
@@ -50,9 +50,7 @@ int32_t GetCSSNameLen(const FX_WCHAR* psz, const FX_WCHAR* pEnd) {
} // namespace
CFDE_CSSStyleSheet::CFDE_CSSStyleSheet()
- : m_wCodePage(FX_CODEPAGE_UTF8),
- m_wRefCount(1),
- m_dwMediaList(FDE_CSSMEDIATYPE_ALL) {
+ : m_wRefCount(1), m_dwMediaList(FDE_CSSMEDIATYPE_ALL) {
ASSERT(m_dwMediaList > 0);
}
@@ -76,19 +74,10 @@ uint32_t CFDE_CSSStyleSheet::Release() {
return dwRefCount;
}
-bool CFDE_CSSStyleSheet::GetUrl(CFX_WideString& szUrl) {
- szUrl = m_szUrl;
- return szUrl.GetLength() > 0;
-}
-
uint32_t CFDE_CSSStyleSheet::GetMediaList() const {
return m_dwMediaList;
}
-uint16_t CFDE_CSSStyleSheet::GetCodePage() const {
- return m_wCodePage;
-}
-
int32_t CFDE_CSSStyleSheet::CountRules() const {
return pdfium::CollectionSize<int32_t>(m_RuleArray);
}
@@ -101,9 +90,6 @@ bool CFDE_CSSStyleSheet::LoadFromBuffer(const FX_WCHAR* pBuffer,
int32_t iBufSize) {
ASSERT(pBuffer && iBufSize > 0);
- m_wCodePage = FX_CODEPAGE_UTF8;
- m_szUrl = CFX_WideString();
-
auto pSyntax = pdfium::MakeUnique<CFDE_CSSSyntaxParser>();
return pSyntax->Init(pBuffer, iBufSize) && LoadFromSyntax(pSyntax.get());
}
diff --git a/xfa/fde/css/fde_cssstylesheet.h b/xfa/fde/css/fde_cssstylesheet.h
index 9cc7b63cbd..aa05a9dda1 100644
--- a/xfa/fde/css/fde_cssstylesheet.h
+++ b/xfa/fde/css/fde_cssstylesheet.h
@@ -100,9 +100,7 @@ class CFDE_CSSStyleSheet : public IFX_Retainable {
bool LoadFromBuffer(const FX_WCHAR* pBuffer, int32_t iBufSize);
- bool GetUrl(CFX_WideString& szUrl);
uint32_t GetMediaList() const;
- uint16_t GetCodePage() const;
int32_t CountRules() const;
CFDE_CSSRule* GetRule(int32_t index);
@@ -120,11 +118,9 @@ class CFDE_CSSStyleSheet : public IFX_Retainable {
std::vector<std::unique_ptr<CFDE_CSSRule>>* ruleArray);
FDE_CSSSyntaxStatus SkipRuleSet(CFDE_CSSSyntaxParser* pSyntax);
- uint16_t m_wCodePage;
uint16_t m_wRefCount;
uint32_t m_dwMediaList;
std::vector<std::unique_ptr<CFDE_CSSRule>> m_RuleArray;
- CFX_WideString m_szUrl;
std::unordered_map<uint32_t, FX_WCHAR*> m_StringCache;
};