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

Side by Side Diff: fpdfsdk/cpdfsdk_xfawidgethandler.cpp

Issue 2323203002: Define behaviors of FPDF_RenderPageBitmap_Retail and FPDF_FFLDraw. (Closed)
Patch Set: roll DEPS 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_widgethandler.cpp ('k') | fpdfsdk/fpdfformfill.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 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_xfawidgethandler.h" 7 #include "fpdfsdk/include/cpdfsdk_xfawidgethandler.h"
8 8
9 #include "core/fpdfdoc/include/cpdf_interform.h" 9 #include "core/fpdfdoc/include/cpdf_interform.h"
10 #include "fpdfsdk/fpdfxfa/include/fpdfxfa_doc.h" 10 #include "fpdfsdk/fpdfxfa/include/fpdfxfa_doc.h"
(...skipping 28 matching lines...) Expand all
39 CPDFSDK_Document* pSDKDoc = m_pApp->GetSDKDocument(); 39 CPDFSDK_Document* pSDKDoc = m_pApp->GetSDKDocument();
40 CPDFSDK_InterForm* pInterForm = pSDKDoc->GetInterForm(); 40 CPDFSDK_InterForm* pInterForm = pSDKDoc->GetInterForm();
41 CPDFSDK_XFAWidget* pWidget = new CPDFSDK_XFAWidget(pAnnot, pPage, pInterForm); 41 CPDFSDK_XFAWidget* pWidget = new CPDFSDK_XFAWidget(pAnnot, pPage, pInterForm);
42 pInterForm->AddXFAMap(pAnnot, pWidget); 42 pInterForm->AddXFAMap(pAnnot, pWidget);
43 return pWidget; 43 return pWidget;
44 } 44 }
45 45
46 void CPDFSDK_XFAWidgetHandler::OnDraw(CPDFSDK_PageView* pPageView, 46 void CPDFSDK_XFAWidgetHandler::OnDraw(CPDFSDK_PageView* pPageView,
47 CPDFSDK_Annot* pAnnot, 47 CPDFSDK_Annot* pAnnot,
48 CFX_RenderDevice* pDevice, 48 CFX_RenderDevice* pDevice,
49 CFX_Matrix* pUser2Device) { 49 CFX_Matrix* pUser2Device,
50 bool bDrawAnnots) {
50 ASSERT(pPageView); 51 ASSERT(pPageView);
51 ASSERT(pAnnot); 52 ASSERT(pAnnot);
52 53
53 CPDFSDK_Document* pSDKDoc = pPageView->GetSDKDocument(); 54 CPDFSDK_Document* pSDKDoc = pPageView->GetSDKDocument();
54 CXFA_FFWidgetHandler* pWidgetHandler = GetXFAWidgetHandler(pAnnot); 55 CXFA_FFWidgetHandler* pWidgetHandler = GetXFAWidgetHandler(pAnnot);
55 56
56 CFX_Graphics gs; 57 CFX_Graphics gs;
57 gs.Create(pDevice); 58 gs.Create(pDevice);
58 59
59 CFX_Matrix mt; 60 CFX_Matrix mt;
(...skipping 305 matching lines...) Expand 10 before | Expand all | Expand 10 after
365 dwFWLFlag |= FWL_KEYFLAG_MButton; 366 dwFWLFlag |= FWL_KEYFLAG_MButton;
366 if (dwFlag & FWL_EVENTFLAG_RightButtonDown) 367 if (dwFlag & FWL_EVENTFLAG_RightButtonDown)
367 dwFWLFlag |= FWL_KEYFLAG_RButton; 368 dwFWLFlag |= FWL_KEYFLAG_RButton;
368 if (dwFlag & FWL_EVENTFLAG_ShiftKey) 369 if (dwFlag & FWL_EVENTFLAG_ShiftKey)
369 dwFWLFlag |= FWL_KEYFLAG_Shift; 370 dwFWLFlag |= FWL_KEYFLAG_Shift;
370 if (dwFlag & FWL_EVENTFLAG_AltKey) 371 if (dwFlag & FWL_EVENTFLAG_AltKey)
371 dwFWLFlag |= FWL_KEYFLAG_Alt; 372 dwFWLFlag |= FWL_KEYFLAG_Alt;
372 373
373 return dwFWLFlag; 374 return dwFWLFlag;
374 } 375 }
OLDNEW
« no previous file with comments | « fpdfsdk/cpdfsdk_widgethandler.cpp ('k') | fpdfsdk/fpdfformfill.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698