summaryrefslogtreecommitdiff
path: root/core/include
diff options
context:
space:
mode:
authorLei Zhang <thestig@chromium.org>2015-11-04 14:16:22 -0800
committerLei Zhang <thestig@chromium.org>2015-11-04 14:16:22 -0800
commit79f5a32175293620abe456554e10efb7c3f4e7c6 (patch)
treea6d9de63ae975548dacf1620a91f92ee9a6fb0a0 /core/include
parent14e83759abec5eca9c4da0b4e8cd5969375a00f4 (diff)
downloadpdfium-79f5a32175293620abe456554e10efb7c3f4e7c6.tar.xz
Make checkdeps --resolve-dotdot succeed.
R=tsepez@chromium.org Review URL: https://codereview.chromium.org/1419373005 .
Diffstat (limited to 'core/include')
-rw-r--r--core/include/fpdfapi/fpdf_parser.h35
-rw-r--r--core/include/fpdfapi/fpdf_render.h14
-rw-r--r--core/include/fxcodec/DEPS3
3 files changed, 42 insertions, 10 deletions
diff --git a/core/include/fpdfapi/fpdf_parser.h b/core/include/fpdfapi/fpdf_parser.h
index b7684e530a..d1f50038a7 100644
--- a/core/include/fpdfapi/fpdf_parser.h
+++ b/core/include/fpdfapi/fpdf_parser.h
@@ -7,7 +7,6 @@
#ifndef CORE_INCLUDE_FPDFAPI_FPDF_PARSER_H_
#define CORE_INCLUDE_FPDFAPI_FPDF_PARSER_H_
-#include "../../../public/fpdf_dataavail.h"
#include "../../../third_party/base/nonstd_unique_ptr.h"
#include "../fxcrt/fx_system.h"
#include "fpdf_objects.h"
@@ -871,6 +870,34 @@ class IFX_DownloadHints {
class IPDF_DataAvail {
public:
+ // Must match PDF_DATA_* definitions in public/fpdf_dataavail.h, but cannot
+ // #include that header. fpdfsdk/src/fpdf_dataavail.cpp has static_asserts
+ // to make sure the two sets of values match.
+ enum DocAvailStatus {
+ DataError = -1, // PDF_DATA_ERROR
+ DataNotAvailable = 0, // PDF_DATA_NOTAVAIL
+ DataAvailable = 1, // PDF_DATA_AVAIL
+ };
+
+ // Must match PDF_*LINEAR* definitions in public/fpdf_dataavail.h, but cannot
+ // #include that header. fpdfsdk/src/fpdf_dataavail.cpp has static_asserts
+ // to make sure the two sets of values match.
+ enum DocLinearizationStatus {
+ LinearizationUnknown = -1, // PDF_LINEARIZATION_UNKNOWN
+ NotLinearized = 0, // PDF_NOT_LINEARIZED
+ Linearized = 1, // PDF_LINEARIZED
+ };
+
+ // Must match PDF_FORM_* definitions in public/fpdf_dataavail.h, but cannot
+ // #include that header. fpdfsdk/src/fpdf_dataavail.cpp has static_asserts
+ // to make sure the two sets of values match.
+ enum DocFormStatus {
+ FormError = -1, // PDF_FORM_ERROR
+ FormNotAvailable = 0, // PDF_FORM_NOTAVAIL
+ FormAvailable = 1, // PDF_FORM_AVAIL
+ FormNotExist = 2, // PDF_FORM_NOTEXIST
+ };
+
static IPDF_DataAvail* Create(IFX_FileAvail* pFileAvail,
IFX_FileRead* pFileRead);
virtual ~IPDF_DataAvail() {}
@@ -878,12 +905,12 @@ class IPDF_DataAvail {
IFX_FileAvail* GetFileAvail() const { return m_pFileAvail; }
IFX_FileRead* GetFileRead() const { return m_pFileRead; }
- virtual int IsDocAvail(IFX_DownloadHints* pHints) = 0;
+ virtual DocAvailStatus IsDocAvail(IFX_DownloadHints* pHints) = 0;
virtual void SetDocument(CPDF_Document* pDoc) = 0;
virtual int IsPageAvail(int iPage, IFX_DownloadHints* pHints) = 0;
virtual FX_BOOL IsLinearized() = 0;
- virtual int IsFormAvail(IFX_DownloadHints* pHints) = 0;
- virtual int IsLinearizedPDF() = 0;
+ virtual DocFormStatus IsFormAvail(IFX_DownloadHints* pHints) = 0;
+ virtual DocLinearizationStatus IsLinearizedPDF() = 0;
virtual void GetLinearizedMainXRefInfo(FX_FILESIZE* pPos,
FX_DWORD* pSize) = 0;
diff --git a/core/include/fpdfapi/fpdf_render.h b/core/include/fpdfapi/fpdf_render.h
index 3c1d95aa8a..7a5251e86e 100644
--- a/core/include/fpdfapi/fpdf_render.h
+++ b/core/include/fpdfapi/fpdf_render.h
@@ -8,7 +8,6 @@
#define CORE_INCLUDE_FPDFAPI_FPDF_RENDER_H_
#include "../../../third_party/base/nonstd_unique_ptr.h"
-#include "../../../public/fpdf_progressive.h"
#include "../fxge/fx_ge.h"
#include "fpdf_page.h"
@@ -134,13 +133,16 @@ class CPDF_RenderContext {
class CPDF_ProgressiveRenderer {
public:
- // Must match FDF_RENDER_* definitions in fpdf_progressive.h.
+ // Must match FDF_RENDER_* definitions in public/fpdf_progressive.h, but
+ // cannot #include that header. fpdfsdk/src/fpdf_progressive.cpp has
+ // static_asserts to make sure the two sets of values match.
enum Status {
- Ready = FPDF_RENDER_READER,
- ToBeContinued = FPDF_RENDER_TOBECOUNTINUED,
- Done = FPDF_RENDER_DONE,
- Failed = FPDF_RENDER_FAILED
+ Ready, // FPDF_RENDER_READER
+ ToBeContinued, // FPDF_RENDER_TOBECOUNTINUED
+ Done, // FPDF_RENDER_DONE
+ Failed // FPDF_RENDER_FAILED
};
+
static int ToFPDFStatus(Status status) { return static_cast<int>(status); }
CPDF_ProgressiveRenderer(CPDF_RenderContext* pContext,
diff --git a/core/include/fxcodec/DEPS b/core/include/fxcodec/DEPS
new file mode 100644
index 0000000000..548eb61a3b
--- /dev/null
+++ b/core/include/fxcodec/DEPS
@@ -0,0 +1,3 @@
+include_rules = [
+ '+third_party/zlib_v128/zlib.h',
+]