summaryrefslogtreecommitdiff
path: root/core/fpdfapi/fpdf_parser/include
diff options
context:
space:
mode:
authordsinclair <dsinclair@chromium.org>2016-09-20 12:35:36 -0700
committerCommit bot <commit-bot@chromium.org>2016-09-20 12:35:36 -0700
commit23e173ad2c48e2683cd6e5f76da3fa188d85bcb8 (patch)
tree15eb27d28b96713b49974d1d2fd9428874c11346 /core/fpdfapi/fpdf_parser/include
parent9f206f05eccf51089fe8a30bf52dc063ea5e2633 (diff)
downloadpdfium-23e173ad2c48e2683cd6e5f76da3fa188d85bcb8.tar.xz
CPDF_Document and CPDF_DataAvail are no longer friends
Remove the friendship between these two classes and replace with accessor methods. Review-Url: https://codereview.chromium.org/2355813002
Diffstat (limited to 'core/fpdfapi/fpdf_parser/include')
-rw-r--r--core/fpdfapi/fpdf_parser/include/cpdf_document.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/core/fpdfapi/fpdf_parser/include/cpdf_document.h b/core/fpdfapi/fpdf_parser/include/cpdf_document.h
index 5f3b2d277a..83567cd85a 100644
--- a/core/fpdfapi/fpdf_parser/include/cpdf_document.h
+++ b/core/fpdfapi/fpdf_parser/include/cpdf_document.h
@@ -51,11 +51,14 @@ class CPDF_Document : public CPDF_IndirectObjectHolder {
void DeletePage(int iPage);
int GetPageCount() const;
+ bool IsPageLoaded(int iPage) const;
CPDF_Dictionary* GetPage(int iPage);
int GetPageIndex(uint32_t objnum);
uint32_t GetUserPermissions() const;
CPDF_DocPageData* GetPageData() const { return m_pDocPage; }
+ void SetPageObjNum(int iPage, uint32_t objNum);
+
std::unique_ptr<JBig2_DocumentContext>* CodecContext() {
return &m_pCodecContext;
}
@@ -97,7 +100,6 @@ class CPDF_Document : public CPDF_IndirectObjectHolder {
protected:
friend class CPDF_Creator;
friend class CPDF_Parser;
- friend class CPDF_DataAvail;
friend class CPDF_OCContext;
// Retrieve page count information by getting count value from the tree nodes
@@ -119,7 +121,6 @@ class CPDF_Document : public CPDF_IndirectObjectHolder {
bool m_bLinearized;
int m_iFirstPageNo;
uint32_t m_dwFirstPageObjNum;
- CFX_ArrayTemplate<uint32_t> m_PageList;
// TODO(thestig): Figure out why this cannot be a std::unique_ptr.
CPDF_DocPageData* m_pDocPage;
std::unique_ptr<CPDF_DocRenderData> m_pDocRender;
@@ -136,6 +137,8 @@ class CPDF_Document : public CPDF_IndirectObjectHolder {
FX_BOOL bVert,
CFX_ByteString basefont,
std::function<void(FX_WCHAR, FX_WCHAR, CPDF_Array*)> Insert);
+
+ CFX_ArrayTemplate<uint32_t> m_PageList;
};
#endif // CORE_FPDFAPI_FPDF_PARSER_INCLUDE_CPDF_DOCUMENT_H_