summaryrefslogtreecommitdiff
path: root/fpdfsdk/src/fpdfxfa
diff options
context:
space:
mode:
authorTom Sepez <tsepez@chromium.org>2016-01-26 13:20:26 -0800
committerTom Sepez <tsepez@chromium.org>2016-01-26 13:20:26 -0800
commit8e5cd19d174f259bfda5f7a9699b08fdc4289b56 (patch)
tree6c2382c4cfe0475ecbfafc1af981dcaa0a801c35 /fpdfsdk/src/fpdfxfa
parentd834d55f902ccd18cba85f93ecf51e30c5e7e47b (diff)
downloadpdfium-8e5cd19d174f259bfda5f7a9699b08fdc4289b56.tar.xz
Merge to XFA: War on #defines, part 1.
Contains additional XFA-specific changes. Original Review URL: https://codereview.chromium.org/1632143002 . (cherry picked from commit 66a9dc9dd65ed2b9c7ede448d046b770140f16d5) R=thestig@chromium.org Review URL: https://codereview.chromium.org/1636503006 .
Diffstat (limited to 'fpdfsdk/src/fpdfxfa')
-rw-r--r--fpdfsdk/src/fpdfxfa/fpdfxfa_doc.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/fpdfsdk/src/fpdfxfa/fpdfxfa_doc.cpp b/fpdfsdk/src/fpdfxfa/fpdfxfa_doc.cpp
index e72c1b3f16..dbd3bd0bad 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;