OLD | NEW |
1 // Copyright 2014 PDFium Authors. All rights reserved. | 1 // Copyright 2014 PDFium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com |
6 | 6 |
7 #include "../include/fsdk_define.h" | 7 #include "../include/fsdk_define.h" |
8 #include "../include/fpdf_dataavail.h" | 8 #include "../include/fpdf_dataavail.h" |
9 | 9 |
10 extern void ProcessParseError(FX_DWORD err_code); | 10 extern void ProcessParseError(FX_DWORD err_code); |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
70 } | 70 } |
71 public: | 71 public: |
72 virtual void AddSegment(FX_FILESIZE offset, FX_DWORD
size) | 72 virtual void AddSegment(FX_FILESIZE offset, FX_DWORD
size) |
73 { | 73 { |
74 m_pDownloadHints->AddSegment(m_pDownloadHints, offset, size); | 74 m_pDownloadHints->AddSegment(m_pDownloadHints, offset, size); |
75 } | 75 } |
76 private: | 76 private: |
77 FX_DOWNLOADHINTS* m_pDownloadHints; | 77 FX_DOWNLOADHINTS* m_pDownloadHints; |
78 }; | 78 }; |
79 | 79 |
80 class CFPDF_DataAvail : public CFX_Object | 80 class CFPDF_DataAvail |
81 { | 81 { |
82 public: | 82 public: |
83 CFPDF_DataAvail() | 83 CFPDF_DataAvail() |
84 { | 84 { |
85 m_pDataAvail = NULL; | 85 m_pDataAvail = NULL; |
86 } | 86 } |
87 | 87 |
88 ~CFPDF_DataAvail() | 88 ~CFPDF_DataAvail() |
89 { | 89 { |
90 if (m_pDataAvail) delete m_pDataAvail; | 90 if (m_pDataAvail) delete m_pDataAvail; |
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
156 CFPDF_DownloadHintsWrap hints_wrap(hints); | 156 CFPDF_DownloadHintsWrap hints_wrap(hints); |
157 return ((CFPDF_DataAvail*)avail)->m_pDataAvail->IsFormAvail(&hints_wrap)
; | 157 return ((CFPDF_DataAvail*)avail)->m_pDataAvail->IsFormAvail(&hints_wrap)
; |
158 } | 158 } |
159 | 159 |
160 DLLEXPORT FPDF_BOOL STDCALL FPDFAvail_IsLinearized(FPDF_AVAIL avail) | 160 DLLEXPORT FPDF_BOOL STDCALL FPDFAvail_IsLinearized(FPDF_AVAIL avail) |
161 { | 161 { |
162 if (avail == NULL) return -1; | 162 if (avail == NULL) return -1; |
163 return ((CFPDF_DataAvail*)avail)->m_pDataAvail->IsLinearizedPDF(); | 163 return ((CFPDF_DataAvail*)avail)->m_pDataAvail->IsLinearizedPDF(); |
164 | 164 |
165 } | 165 } |
OLD | NEW |