From a1b0772321e9b839073b9b312bac22143f2d4011 Mon Sep 17 00:00:00 2001 From: dsinclair Date: Mon, 11 Jul 2016 08:20:58 -0700 Subject: Remove IXFA_Parser, cleanup XFA parser code. The IXFA_Parser only created a CXFA_SimpleParser, the CXFA_DocumentParser is only created in one spot and doesn't need all the IXFA_Parser methods. This CL removes IXFA_Parser, instantiates the CXFA_SimpleParser where needed and cleans up surrounding code. Review-Url: https://codereview.chromium.org/2123133004 --- xfa/fxfa/parser/xfa_document_imp.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'xfa/fxfa/parser/xfa_document_imp.cpp') diff --git a/xfa/fxfa/parser/xfa_document_imp.cpp b/xfa/fxfa/parser/xfa_document_imp.cpp index 7ba85bb35c..efd48e66a1 100644 --- a/xfa/fxfa/parser/xfa_document_imp.cpp +++ b/xfa/fxfa/parser/xfa_document_imp.cpp @@ -12,7 +12,6 @@ #include "xfa/fxfa/parser/xfa_document_layout_imp.h" #include "xfa/fxfa/parser/xfa_localemgr.h" #include "xfa/fxfa/parser/xfa_object.h" -#include "xfa/fxfa/parser/xfa_parser.h" #include "xfa/fxfa/parser/xfa_parser_imp.h" #include "xfa/fxfa/parser/xfa_script.h" #include "xfa/fxfa/parser/xfa_script_datawindow.h" @@ -74,6 +73,10 @@ void CXFA_Document::SetRoot(CXFA_Node* pNewRoot) { RemovePurgeNode(pNewRoot); } +CFDE_XMLDoc* CXFA_Document::GetXMLDoc() const { + return m_pParser->GetXMLDoc(); +} + CXFA_FFNotify* CXFA_Document::GetNotify() const { return m_pParser->GetNotify(); } @@ -219,7 +222,7 @@ FX_BOOL CXFA_Document::IsInteractive() { CXFA_LocaleMgr* CXFA_Document::GetLocalMgr() { if (!m_pLocalMgr) { CFX_WideString wsLanguage; - GetParser()->GetNotify()->GetAppProvider()->GetLanguage(wsLanguage); + GetNotify()->GetAppProvider()->GetLanguage(wsLanguage); m_pLocalMgr = new CXFA_LocaleMgr( ToNode(GetXFAObject(XFA_HASHCODE_LocaleSet)), wsLanguage); } -- cgit v1.2.3