Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(725)

Unified Diff: core/fpdfapi/fpdf_parser/cpdf_document.cpp

Issue 2355813002: CPDF_Document and CPDF_DataAvail are no longer friends (Closed)
Patch Set: const Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « core/fpdfapi/fpdf_parser/cpdf_data_avail.cpp ('k') | core/fpdfapi/fpdf_parser/include/cpdf_document.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: core/fpdfapi/fpdf_parser/cpdf_document.cpp
diff --git a/core/fpdfapi/fpdf_parser/cpdf_document.cpp b/core/fpdfapi/fpdf_parser/cpdf_document.cpp
index d3909ceaec2ee579f6fd9036baf4c0eaa6316c34..020e3544e9f5bec6db730e1bf62fbf5d54e8e931 100644
--- a/core/fpdfapi/fpdf_parser/cpdf_document.cpp
+++ b/core/fpdfapi/fpdf_parser/cpdf_document.cpp
@@ -512,6 +512,10 @@ CPDF_Dictionary* CPDF_Document::GetPagesDict() const {
return pRoot ? pRoot->GetDictFor("Pages") : nullptr;
}
+bool CPDF_Document::IsPageLoaded(int iPage) const {
+ return !!m_PageList.GetAt(iPage);
+}
+
CPDF_Dictionary* CPDF_Document::GetPage(int iPage) {
if (iPage < 0 || iPage >= m_PageList.GetSize())
return nullptr;
@@ -541,6 +545,10 @@ CPDF_Dictionary* CPDF_Document::GetPage(int iPage) {
return pPage;
}
+void CPDF_Document::SetPageObjNum(int iPage, uint32_t objNum) {
+ m_PageList.SetAt(iPage, objNum);
+}
+
int CPDF_Document::FindPageIndex(CPDF_Dictionary* pNode,
uint32_t& skip_count,
uint32_t objnum,
« no previous file with comments | « core/fpdfapi/fpdf_parser/cpdf_data_avail.cpp ('k') | core/fpdfapi/fpdf_parser/include/cpdf_document.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698