Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(28)

Side by Side Diff: fpdfsdk/formfiller/cffl_formfiller.cpp

Issue 2287703002: Rename CPDFSDK_Annot::GetType to CPDFSDK_Annot::GetAnnotSubtype. (Closed)
Patch Set: Rename CPDFSDK_Annot::GetType to CPDFSDK_Annot::GetAnnotSubtype. Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « fpdfsdk/cpdfsdk_xfawidget.cpp ('k') | fpdfsdk/formfiller/cffl_iformfiller.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/formfiller/cffl_formfiller.h" 7 #include "fpdfsdk/formfiller/cffl_formfiller.h"
8 8
9 #include "core/fpdfapi/fpdf_page/include/cpdf_page.h" 9 #include "core/fpdfapi/fpdf_page/include/cpdf_page.h"
10 #include "core/fxge/include/cfx_renderdevice.h" 10 #include "core/fxge/include/cfx_renderdevice.h"
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
78 CFX_FloatRect rect = CPWL_Utils::InflateRect(rcWin, 1); 78 CFX_FloatRect rect = CPWL_Utils::InflateRect(rcWin, 1);
79 79
80 return rect.GetOuterRect(); 80 return rect.GetOuterRect();
81 } 81 }
82 82
83 void CFFL_FormFiller::OnDraw(CPDFSDK_PageView* pPageView, 83 void CFFL_FormFiller::OnDraw(CPDFSDK_PageView* pPageView,
84 CPDFSDK_Annot* pAnnot, 84 CPDFSDK_Annot* pAnnot,
85 CFX_RenderDevice* pDevice, 85 CFX_RenderDevice* pDevice,
86 CFX_Matrix* pUser2Device, 86 CFX_Matrix* pUser2Device,
87 uint32_t dwFlags) { 87 uint32_t dwFlags) {
88 ASSERT(pAnnot->GetPDFAnnot()->GetSubType() == "Widget"); 88 ASSERT(pAnnot->GetPDFAnnot()->GetSubtype() == "Widget");
89 89
90 if (CPWL_Wnd* pWnd = GetPDFWindow(pPageView, FALSE)) { 90 if (CPWL_Wnd* pWnd = GetPDFWindow(pPageView, FALSE)) {
91 CFX_Matrix mt = GetCurMatrix(); 91 CFX_Matrix mt = GetCurMatrix();
92 mt.Concat(*pUser2Device); 92 mt.Concat(*pUser2Device);
93 pWnd->DrawAppearance(pDevice, &mt); 93 pWnd->DrawAppearance(pDevice, &mt);
94 } else { 94 } else {
95 CPDFSDK_Widget* pWidget = (CPDFSDK_Widget*)pAnnot; 95 CPDFSDK_Widget* pWidget = (CPDFSDK_Widget*)pAnnot;
96 if (CFFL_IFormFiller::IsVisible(pWidget)) 96 if (CFFL_IFormFiller::IsVisible(pWidget))
97 pWidget->DrawAppearance(pDevice, pUser2Device, CPDF_Annot::Normal, 97 pWidget->DrawAppearance(pDevice, pUser2Device, CPDF_Annot::Normal,
98 nullptr); 98 nullptr);
(...skipping 618 matching lines...) Expand 10 before | Expand all | Expand 10 after
717 } 717 }
718 } 718 }
719 719
720 void CFFL_Button::OnDrawDeactive(CPDFSDK_PageView* pPageView, 720 void CFFL_Button::OnDrawDeactive(CPDFSDK_PageView* pPageView,
721 CPDFSDK_Annot* pAnnot, 721 CPDFSDK_Annot* pAnnot,
722 CFX_RenderDevice* pDevice, 722 CFX_RenderDevice* pDevice,
723 CFX_Matrix* pUser2Device, 723 CFX_Matrix* pUser2Device,
724 uint32_t dwFlags) { 724 uint32_t dwFlags) {
725 OnDraw(pPageView, pAnnot, pDevice, pUser2Device, dwFlags); 725 OnDraw(pPageView, pAnnot, pDevice, pUser2Device, dwFlags);
726 } 726 }
OLDNEW
« no previous file with comments | « fpdfsdk/cpdfsdk_xfawidget.cpp ('k') | fpdfsdk/formfiller/cffl_iformfiller.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698