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

Unified Diff: core/fpdfapi/fpdf_edit/fpdf_edit_create.cpp

Issue 2349353003: CPDF_Document friend cleanup (Closed)
Patch Set: Rebase to master 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 | « no previous file | 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_edit/fpdf_edit_create.cpp
diff --git a/core/fpdfapi/fpdf_edit/fpdf_edit_create.cpp b/core/fpdfapi/fpdf_edit/fpdf_edit_create.cpp
index 36f622664d78042b09f70d11d86c9f99b494e5f6..45b8711efdb32ddc9fe4761a77e74589c98bcc1d 100644
--- a/core/fpdfapi/fpdf_edit/fpdf_edit_create.cpp
+++ b/core/fpdfapi/fpdf_edit/fpdf_edit_create.cpp
@@ -929,7 +929,7 @@ int32_t CPDF_Creator::WriteIndirectObjectToStream(const CPDF_Object* pObj) {
}
if (pDict) {
- if (pDict == m_pDocument->m_pRootDict || pDict == m_pEncryptDict)
+ if (pDict == m_pDocument->GetRoot() || pDict == m_pEncryptDict)
return 1;
if (pDict->IsSignatureDict())
return 1;
@@ -1749,17 +1749,17 @@ int32_t CPDF_Creator::WriteDoc_Stage4(IFX_Pause* pPause) {
if (m_File.AppendString("\r\n/Root ") < 0) {
return -1;
}
- if (m_File.AppendDWord(m_pDocument->m_pRootDict->GetObjNum()) < 0) {
+ if (m_File.AppendDWord(m_pDocument->GetRoot()->GetObjNum()) < 0) {
return -1;
}
if (m_File.AppendString(" 0 R\r\n") < 0) {
return -1;
}
- if (m_pDocument->m_pInfoDict) {
+ if (m_pDocument->GetInfo()) {
if (m_File.AppendString("/Info ") < 0) {
return -1;
}
- if (m_File.AppendDWord(m_pDocument->m_pInfoDict->GetObjNum()) < 0) {
+ if (m_File.AppendDWord(m_pDocument->GetInfo()->GetObjNum()) < 0) {
return -1;
}
if (m_File.AppendString(" 0 R\r\n") < 0) {
« no previous file with comments | « no previous file | core/fpdfapi/fpdf_parser/include/cpdf_document.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698