diff options
author | Dan Sinclair <dsinclair@chromium.org> | 2018-04-12 13:23:08 +0000 |
---|---|---|
committer | Chromium commit bot <commit-bot@chromium.org> | 2018-04-12 13:23:08 +0000 |
commit | 0cad1163af80cfcc987a3d431fbd05fa3e09151b (patch) | |
tree | ef67e8051351985ed66e467683084e8f88b8e24f /xfa/fxfa/cxfa_ffdoc.h | |
parent | 2efb11c89ee200473f5675ba3d3a946d5606e813 (diff) | |
download | pdfium-0cad1163af80cfcc987a3d431fbd05fa3e09151b.tar.xz |
Fold CXFA_DocumentParser into CXFA_FFDoc
The CXFA_DocumentParser is a thin wrapper around CXFA_SimpleParser. This
CL folds CXFA_DocumentParser into a ParseDoc method of CXFA_FFDoc.
Change-Id: I7e7073899436f0435c4ebfd548241ae842a2a276
Reviewed-on: https://pdfium-review.googlesource.com/30213
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
Diffstat (limited to 'xfa/fxfa/cxfa_ffdoc.h')
-rw-r--r-- | xfa/fxfa/cxfa_ffdoc.h | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/xfa/fxfa/cxfa_ffdoc.h b/xfa/fxfa/cxfa_ffdoc.h index 59b3f57cac..fd90471f23 100644 --- a/xfa/fxfa/cxfa_ffdoc.h +++ b/xfa/fxfa/cxfa_ffdoc.h @@ -10,10 +10,11 @@ #include <map> #include <memory> +#include "core/fxcrt/fx_stream.h" #include "core/fxcrt/unowned_ptr.h" +#include "core/fxcrt/xml/cfx_xmlnode.h" #include "xfa/fxfa/fxfa.h" #include "xfa/fxfa/parser/cxfa_document.h" -#include "xfa/fxfa/parser/cxfa_document_parser.h" class CFGAS_PDFFontMgr; class CFX_ChecksumContext; @@ -62,10 +63,11 @@ class CXFA_FFDoc { CXFA_FFDocView* CreateDocView(); + bool ParseDoc(); bool OpenDoc(CPDF_Document* pPDFDoc); void CloseDoc(); - CXFA_Document* GetXFADoc() const { return m_pDocumentParser->GetDocument(); } + CXFA_Document* GetXFADoc() const { return m_pDocument.get(); } CXFA_FFApp* GetApp() const { return m_pApp.Get(); } CPDF_Document* GetPDFDoc() const { return m_pPDFDoc.Get(); } CXFA_FFDocView* GetDocView(CXFA_LayoutProcessor* pLayout); @@ -82,7 +84,8 @@ class CXFA_FFDoc { private: UnownedPtr<IXFA_DocEnvironment> const m_pDocEnvironment; - std::unique_ptr<CXFA_DocumentParser> m_pDocumentParser; + std::unique_ptr<CFX_XMLNode> m_pXMLRoot; + std::unique_ptr<CXFA_Document> m_pDocument; RetainPtr<IFX_SeekableStream> m_pStream; UnownedPtr<CXFA_FFApp> const m_pApp; std::unique_ptr<CXFA_FFNotify> m_pNotify; |