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

Unified Diff: fpdfsdk/src/fpdfxfa/fpdfxfa_doc.cpp

Issue 1636503006: Merge to XFA: War on #defines, part 1. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@xfa
Patch Set: Dircet -> Direct typo. Created 4 years, 11 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 | « fpdfsdk/src/fpdfsave.cpp ('k') | fpdfsdk/src/javascript/Document.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: fpdfsdk/src/fpdfxfa/fpdfxfa_doc.cpp
diff --git a/fpdfsdk/src/fpdfxfa/fpdfxfa_doc.cpp b/fpdfsdk/src/fpdfxfa/fpdfxfa_doc.cpp
index e72c1b3f16410d2e69e5129cbb94885b11078be9..dbd3bd0bade40246607eef397c915ae3a711c448 100644
--- a/fpdfsdk/src/fpdfxfa/fpdfxfa_doc.cpp
+++ b/fpdfsdk/src/fpdfxfa/fpdfxfa_doc.cpp
@@ -648,7 +648,7 @@ void CPDFXFA_Document::ExportData(IXFA_Doc* hDoc,
CPDF_Object* pXFA = pAcroForm->GetElement("XFA");
if (pXFA == NULL)
return;
- if (pXFA->GetType() != PDFOBJ_ARRAY)
+ if (!pXFA->IsArray())
return;
CPDF_Array* pArray = pXFA->GetArray();
if (NULL == pArray)
@@ -657,12 +657,12 @@ void CPDFXFA_Document::ExportData(IXFA_Doc* hDoc,
for (int i = 1; i < size; i += 2) {
CPDF_Object* pPDFObj = pArray->GetElement(i);
CPDF_Object* pPrePDFObj = pArray->GetElement(i - 1);
- if (pPrePDFObj->GetType() != PDFOBJ_STRING)
+ if (!pPrePDFObj->IsString())
continue;
- if (pPDFObj->GetType() != PDFOBJ_REFERENCE)
+ if (!pPDFObj->IsReference())
continue;
CPDF_Object* pDirectObj = pPDFObj->GetDirect();
- if (pDirectObj->GetType() != PDFOBJ_STREAM)
+ if (!pDirectObj->IsStream())
continue;
if (pPrePDFObj->GetString() == "form") {
CFX_WideStringC form(L"form");
@@ -965,7 +965,7 @@ FX_BOOL CPDFXFA_Document::_ExportSubmitFile(FPDF_FILEHANDLER* pFileHandler,
fileStream.Flush();
return FALSE;
}
- if (pXFA->GetType() != PDFOBJ_ARRAY) {
+ if (!pXFA->IsArray()) {
fileStream.Flush();
return FALSE;
}
@@ -978,12 +978,12 @@ FX_BOOL CPDFXFA_Document::_ExportSubmitFile(FPDF_FILEHANDLER* pFileHandler,
for (int i = 1; i < size; i += 2) {
CPDF_Object* pPDFObj = pArray->GetElement(i);
CPDF_Object* pPrePDFObj = pArray->GetElement(i - 1);
- if (pPrePDFObj->GetType() != PDFOBJ_STRING)
+ if (!pPrePDFObj->IsString())
continue;
- if (pPDFObj->GetType() != PDFOBJ_REFERENCE)
+ if (!pPDFObj->IsReference())
continue;
CPDF_Object* pDirectObj = pPDFObj->GetDirect();
- if (pDirectObj->GetType() != PDFOBJ_STREAM)
+ if (!pDirectObj->IsStream())
continue;
if (pPrePDFObj->GetString() == "config" && !(flag & FXFA_CONFIG))
continue;
« no previous file with comments | « fpdfsdk/src/fpdfsave.cpp ('k') | fpdfsdk/src/javascript/Document.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698