summaryrefslogtreecommitdiff
path: root/core/fpdfapi/page
diff options
context:
space:
mode:
authorLei Zhang <thestig@chromium.org>2018-05-08 00:00:16 +0000
committerChromium commit bot <commit-bot@chromium.org>2018-05-08 00:00:16 +0000
commite5c0fa97c2da104426dbc1cecfc0ed488a22efe5 (patch)
treef98799cbca4694a7f20fbc0816d422a1147368b8 /core/fpdfapi/page
parent8f63763317ae1ef65d1ac2719624adeb728f2207 (diff)
downloadpdfium-e5c0fa97c2da104426dbc1cecfc0ed488a22efe5.tar.xz
Make one more CPDF_PageObjectHolder member protected.
Change-Id: Id9288d504f063759f69632ab59b0a21569ff76d8 Reviewed-on: https://pdfium-review.googlesource.com/32113 Commit-Queue: Lei Zhang <thestig@chromium.org> Reviewed-by: dsinclair <dsinclair@chromium.org>
Diffstat (limited to 'core/fpdfapi/page')
-rw-r--r--core/fpdfapi/page/cpdf_contentparser.cpp12
-rw-r--r--core/fpdfapi/page/cpdf_pageobjectholder.h2
2 files changed, 7 insertions, 7 deletions
diff --git a/core/fpdfapi/page/cpdf_contentparser.cpp b/core/fpdfapi/page/cpdf_contentparser.cpp
index dcdf138779..f558ac823a 100644
--- a/core/fpdfapi/page/cpdf_contentparser.cpp
+++ b/core/fpdfapi/page/cpdf_contentparser.cpp
@@ -24,12 +24,12 @@
CPDF_ContentParser::CPDF_ContentParser(CPDF_Page* pPage)
: m_InternalStage(STAGE_GETCONTENT), m_pObjectHolder(pPage) {
- if (!pPage || !pPage->GetDocument() || !pPage->m_pFormDict) {
+ if (!pPage || !pPage->GetDocument() || !pPage->GetFormDict()) {
m_bIsDone = true;
return;
}
- CPDF_Object* pContent = pPage->m_pFormDict->GetDirectObjectFor("Contents");
+ CPDF_Object* pContent = pPage->GetFormDict()->GetDirectObjectFor("Contents");
if (!pContent) {
m_bIsDone = true;
return;
@@ -61,11 +61,11 @@ CPDF_ContentParser::CPDF_ContentParser(CPDF_Form* pForm,
: m_InternalStage(STAGE_PARSE),
m_pObjectHolder(pForm),
m_pType3Char(pType3Char) {
- CFX_Matrix form_matrix = pForm->m_pFormDict->GetMatrixFor("Matrix");
+ CFX_Matrix form_matrix = pForm->GetFormDict()->GetMatrixFor("Matrix");
if (pGraphicStates)
form_matrix.Concat(pGraphicStates->m_CTM);
- CPDF_Array* pBBox = pForm->m_pFormDict->GetArrayFor("BBox");
+ CPDF_Array* pBBox = pForm->GetFormDict()->GetArrayFor("BBox");
CFX_FloatRect form_bbox;
CPDF_Path ClipPath;
if (pBBox) {
@@ -82,7 +82,7 @@ CPDF_ContentParser::CPDF_ContentParser(CPDF_Form* pForm,
form_bbox = pParentMatrix->TransformRect(form_bbox);
}
- CPDF_Dictionary* pResources = pForm->m_pFormDict->GetDictFor("Resources");
+ CPDF_Dictionary* pResources = pForm->GetFormDict()->GetDictFor("Resources");
m_pParser = pdfium::MakeUnique<CPDF_StreamContentParser>(
pForm->GetDocument(), pForm->m_pPageResources.Get(),
pForm->m_pResources.Get(), pParentMatrix, pForm, pResources, form_bbox,
@@ -144,7 +144,7 @@ bool CPDF_ContentParser::Continue(PauseIndicatorIface* pPause) {
m_CurrentOffset = 0;
} else {
CPDF_Array* pContent =
- m_pObjectHolder->m_pFormDict->GetArrayFor("Contents");
+ m_pObjectHolder->GetFormDict()->GetArrayFor("Contents");
CPDF_Stream* pStreamObj = ToStream(
pContent ? pContent->GetDirectObjectAt(m_CurrentOffset) : nullptr);
m_StreamArray[m_CurrentOffset] =
diff --git a/core/fpdfapi/page/cpdf_pageobjectholder.h b/core/fpdfapi/page/cpdf_pageobjectholder.h
index 54c4f2b063..b26fc0d0e2 100644
--- a/core/fpdfapi/page/cpdf_pageobjectholder.h
+++ b/core/fpdfapi/page/cpdf_pageobjectholder.h
@@ -87,7 +87,6 @@ class CPDF_PageObjectHolder {
void Transform(const CFX_Matrix& matrix);
CFX_FloatRect CalcBoundingBox() const;
- const UnownedPtr<CPDF_Dictionary> m_pFormDict;
UnownedPtr<CPDF_Stream> m_pFormStream;
UnownedPtr<CPDF_Dictionary> m_pPageResources;
UnownedPtr<CPDF_Dictionary> m_pResources;
@@ -99,6 +98,7 @@ class CPDF_PageObjectHolder {
void LoadTransInfo();
+ const UnownedPtr<CPDF_Dictionary> m_pFormDict;
UnownedPtr<CPDF_Document> m_pDocument;
CFX_FloatRect m_BBox;
int m_iTransparency = 0;