OLD | NEW |
1 // Copyright 2016 PDFium Authors. All rights reserved. | 1 // Copyright 2016 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/cpdfsdk_baannot.h" | 7 #include "fpdfsdk/include/cpdfsdk_baannot.h" |
8 | 8 |
9 #include "core/fpdfapi/fpdf_parser/include/cpdf_array.h" | 9 #include "core/fpdfapi/fpdf_parser/include/cpdf_array.h" |
| 10 #include "core/fpdfapi/fpdf_parser/include/cpdf_document.h" |
10 #include "core/fpdfapi/fpdf_parser/include/cpdf_number.h" | 11 #include "core/fpdfapi/fpdf_parser/include/cpdf_number.h" |
11 #include "core/fpdfapi/fpdf_parser/include/cpdf_stream.h" | 12 #include "core/fpdfapi/fpdf_parser/include/cpdf_stream.h" |
12 #include "core/fpdfapi/fpdf_parser/include/fpdf_parser_decode.h" | 13 #include "core/fpdfapi/fpdf_parser/include/fpdf_parser_decode.h" |
13 #include "fpdfsdk/include/cpdfsdk_datetime.h" | 14 #include "fpdfsdk/include/cpdfsdk_datetime.h" |
14 #include "fpdfsdk/include/fsdk_mgr.h" | 15 #include "fpdfsdk/include/cpdfsdk_document.h" |
| 16 #include "fpdfsdk/include/cpdfsdk_pageview.h" |
15 | 17 |
16 CPDFSDK_BAAnnot::CPDFSDK_BAAnnot(CPDF_Annot* pAnnot, | 18 CPDFSDK_BAAnnot::CPDFSDK_BAAnnot(CPDF_Annot* pAnnot, |
17 CPDFSDK_PageView* pPageView) | 19 CPDFSDK_PageView* pPageView) |
18 : CPDFSDK_Annot(pPageView), m_pAnnot(pAnnot) {} | 20 : CPDFSDK_Annot(pPageView), m_pAnnot(pAnnot) {} |
19 | 21 |
20 CPDFSDK_BAAnnot::~CPDFSDK_BAAnnot() {} | 22 CPDFSDK_BAAnnot::~CPDFSDK_BAAnnot() {} |
21 | 23 |
22 CPDF_Annot* CPDFSDK_BAAnnot::GetPDFAnnot() const { | 24 CPDF_Annot* CPDFSDK_BAAnnot::GetPDFAnnot() const { |
23 return m_pAnnot; | 25 return m_pAnnot; |
24 } | 26 } |
(...skipping 373 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
398 CPDF_RenderOptions* pOptions) { | 400 CPDF_RenderOptions* pOptions) { |
399 m_pAnnot->GetAPForm(m_pPageView->GetPDFPage(), CPDF_Annot::Normal); | 401 m_pAnnot->GetAPForm(m_pPageView->GetPDFPage(), CPDF_Annot::Normal); |
400 m_pAnnot->DrawAppearance(m_pPageView->GetPDFPage(), pDevice, pUser2Device, | 402 m_pAnnot->DrawAppearance(m_pPageView->GetPDFPage(), pDevice, pUser2Device, |
401 CPDF_Annot::Normal, nullptr); | 403 CPDF_Annot::Normal, nullptr); |
402 } | 404 } |
403 | 405 |
404 void CPDFSDK_BAAnnot::SetOpenState(bool bOpenState) { | 406 void CPDFSDK_BAAnnot::SetOpenState(bool bOpenState) { |
405 if (CPDF_Annot* pAnnot = m_pAnnot->GetPopupAnnot()) | 407 if (CPDF_Annot* pAnnot = m_pAnnot->GetPopupAnnot()) |
406 pAnnot->SetOpenState(bOpenState); | 408 pAnnot->SetOpenState(bOpenState); |
407 } | 409 } |
OLD | NEW |