| 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 "fpdfsdk/include/pdfwindow/PDFWindow.h" | 7 #include "fpdfsdk/include/pdfwindow/PDFWindow.h" |
| 8 #include "fpdfsdk/include/pdfwindow/PWL_FontMap.h" | 8 #include "fpdfsdk/include/pdfwindow/PWL_FontMap.h" |
| 9 #include "fpdfsdk/include/pdfwindow/PWL_Wnd.h" | 9 #include "fpdfsdk/include/pdfwindow/PWL_Wnd.h" |
| 10 | 10 |
| 11 #define DEFAULT_FONT_NAME "Helvetica" | 11 #define DEFAULT_FONT_NAME "Helvetica" |
| 12 | 12 |
| 13 /* ------------------------------ CPWL_FontMap ------------------------------ */ | 13 /* ------------------------------ CPWL_FontMap ------------------------------ */ |
| 14 | 14 |
| 15 CPWL_FontMap::CPWL_FontMap(IFX_SystemHandler* pSystemHandler) | 15 CPWL_FontMap::CPWL_FontMap(IFX_SystemHandler* pSystemHandler) |
| 16 : m_pPDFDoc(NULL), m_pSystemHandler(pSystemHandler) { | 16 : m_pPDFDoc(NULL), m_pSystemHandler(pSystemHandler) { |
| 17 ASSERT(m_pSystemHandler != NULL); | 17 ASSERT(m_pSystemHandler); |
| 18 } | 18 } |
| 19 | 19 |
| 20 CPWL_FontMap::~CPWL_FontMap() { | 20 CPWL_FontMap::~CPWL_FontMap() { |
| 21 delete m_pPDFDoc; | 21 delete m_pPDFDoc; |
| 22 m_pPDFDoc = NULL; | 22 m_pPDFDoc = NULL; |
| 23 | 23 |
| 24 Empty(); | 24 Empty(); |
| 25 } | 25 } |
| 26 | 26 |
| 27 void CPWL_FontMap::SetSystemHandler(IFX_SystemHandler* pSystemHandler) { | 27 void CPWL_FontMap::SetSystemHandler(IFX_SystemHandler* pSystemHandler) { |
| (...skipping 480 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 508 | 508 |
| 509 CPWL_DocFontMap::CPWL_DocFontMap(IFX_SystemHandler* pSystemHandler, | 509 CPWL_DocFontMap::CPWL_DocFontMap(IFX_SystemHandler* pSystemHandler, |
| 510 CPDF_Document* pAttachedDoc) | 510 CPDF_Document* pAttachedDoc) |
| 511 : CPWL_FontMap(pSystemHandler), m_pAttachedDoc(pAttachedDoc) {} | 511 : CPWL_FontMap(pSystemHandler), m_pAttachedDoc(pAttachedDoc) {} |
| 512 | 512 |
| 513 CPWL_DocFontMap::~CPWL_DocFontMap() {} | 513 CPWL_DocFontMap::~CPWL_DocFontMap() {} |
| 514 | 514 |
| 515 CPDF_Document* CPWL_DocFontMap::GetDocument() { | 515 CPDF_Document* CPWL_DocFontMap::GetDocument() { |
| 516 return m_pAttachedDoc; | 516 return m_pAttachedDoc; |
| 517 } | 517 } |
| OLD | NEW |