| 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/fpdfapi/fpdf_parser.h" | 7 #include "../../../include/fpdfapi/fpdf_parser.h" |
| 8 #include "../../../include/fpdfapi/fpdf_module.h" | 8 #include "../../../include/fpdfapi/fpdf_module.h" |
| 9 extern FX_LPVOID PDFPreviewInitCache(CPDF_Document* pDoc); | 9 |
| 10 extern void PDFPreviewClearCache(FX_LPVOID pCache); | 10 CPDF_Document::CPDF_Document(CPDF_Parser* pParser) : CPDF_IndirectObjects(pParse
r) |
| 11 CPDF_Document::CPDF_Document(IPDF_DocParser* pParser) : CPDF_IndirectObjects(pPa
rser) | |
| 12 { | 11 { |
| 13 ASSERT(pParser != NULL); | 12 ASSERT(pParser != NULL); |
| 14 m_pRootDict = NULL; | 13 m_pRootDict = NULL; |
| 15 m_pInfoDict = NULL; | 14 m_pInfoDict = NULL; |
| 16 m_bLinearized = FALSE; | 15 m_bLinearized = FALSE; |
| 17 m_dwFirstPageNo = 0; | 16 m_dwFirstPageNo = 0; |
| 18 m_dwFirstPageObjNum = 0; | 17 m_dwFirstPageObjNum = 0; |
| 19 m_pDocPage = CPDF_ModuleMgr::Get()->GetPageModule()->CreateDocData(this); | 18 m_pDocPage = CPDF_ModuleMgr::Get()->GetPageModule()->CreateDocData(this); |
| 20 m_pDocRender = CPDF_ModuleMgr::Get()->GetRenderModule()->CreateDocData(this)
; | 19 m_pDocRender = CPDF_ModuleMgr::Get()->GetRenderModule()->CreateDocData(this)
; |
| 21 } | 20 } |
| (...skipping 372 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 394 if (m_pDocPage) { | 393 if (m_pDocPage) { |
| 395 CPDF_ModuleMgr::Get()->GetPageModule()->ClearDoc(this); | 394 CPDF_ModuleMgr::Get()->GetPageModule()->ClearDoc(this); |
| 396 } | 395 } |
| 397 } | 396 } |
| 398 void CPDF_Document::ClearRenderData() | 397 void CPDF_Document::ClearRenderData() |
| 399 { | 398 { |
| 400 if (m_pDocRender) { | 399 if (m_pDocRender) { |
| 401 CPDF_ModuleMgr::Get()->GetRenderModule()->ClearDocData(m_pDocRender); | 400 CPDF_ModuleMgr::Get()->GetRenderModule()->ClearDocData(m_pDocRender); |
| 402 } | 401 } |
| 403 } | 402 } |
| OLD | NEW |