summaryrefslogtreecommitdiff
path: root/fpdfsdk/include/fsdk_mgr.h
diff options
context:
space:
mode:
authorTom Sepez <tsepez@chromium.org>2015-10-21 14:07:23 -0700
committerTom Sepez <tsepez@chromium.org>2015-10-21 14:07:23 -0700
commitbf59a070593d079256161f6ff47148df309668c7 (patch)
tree0c105507a20881f8f025127183510fefb851c3ce /fpdfsdk/include/fsdk_mgr.h
parent63dfaab17af7121653749bc86d11fc77b5353dca (diff)
downloadpdfium-bf59a070593d079256161f6ff47148df309668c7.tar.xz
XFA: add CPDFDocumentToFPDFDocument()
Abstracts away that master returns CPDF_Documents directly, but XFA wraps them with a CPDFXFA_Document. Tidy dead code along the way. R=thestig@chromium.org Review URL: https://codereview.chromium.org/1415803002 .
Diffstat (limited to 'fpdfsdk/include/fsdk_mgr.h')
-rw-r--r--fpdfsdk/include/fsdk_mgr.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/fpdfsdk/include/fsdk_mgr.h b/fpdfsdk/include/fsdk_mgr.h
index 4c0ce1ea27..300ca2287e 100644
--- a/fpdfsdk/include/fsdk_mgr.h
+++ b/fpdfsdk/include/fsdk_mgr.h
@@ -475,7 +475,10 @@ class CPDFSDK_Document {
~CPDFSDK_Document();
CPDFSDK_InterForm* GetInterForm();
- CPDFXFA_Document* GetDocument() { return m_pDoc; }
+ CPDFXFA_Document* GetDocument() const { return m_pDoc; }
+ CPDF_Document* GetPDFDocument() const {
+ return m_pDoc ? m_pDoc->GetPDFDoc() : nullptr;
+ }
int GetPageViewCount() const { return m_pageMap.size(); }
CPDFSDK_PageView* GetPageView(CPDFXFA_Page* pPDFXFAPage,