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

Side by Side Diff: fpdfsdk/include/cpdfsdk_xfaannothandler.h

Issue 2243623002: Split fpdfsdk/fsdk_annothandler.h into individual classes. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Split fpdfsdk/fsdk_annothandler.h into individual classes. Created 4 years, 4 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/include/cpdfsdk_bfannothandler.h ('k') | fpdfsdk/include/fsdk_annothandler.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2016 PDFium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
6
7 #ifndef FPDFSDK_INCLUDE_CPDFSDK_XFAANNOTHANDLER_H_
8 #define FPDFSDK_INCLUDE_CPDFSDK_XFAANNOTHANDLER_H_
9
10 #ifdef PDF_ENABLE_XFA
11
12 #include "core/fxcrt/include/fx_basic.h"
13 #include "core/fxcrt/include/fx_coordinates.h"
14 #include "fpdfsdk/include/ipdfsdk_annothandler.h"
15
16 class CFX_Matrix;
17 class CFX_RenderDevice;
18 class CPDF_Annot;
19 class CPDFDoc_Environment;
20 class CPDFSDK_Annot;
21 class CPDFSDK_PageView;
22 class CXFA_FFWidget;
23 class CXFA_FFWidgetHandler;
24
25 class CPDFSDK_XFAAnnotHandler : public IPDFSDK_AnnotHandler {
26 public:
27 explicit CPDFSDK_XFAAnnotHandler(CPDFDoc_Environment* pApp);
28 ~CPDFSDK_XFAAnnotHandler() override;
29
30 CFX_ByteString GetType() override;
31 CFX_ByteString GetName() override;
32 FX_BOOL CanAnswer(CPDFSDK_Annot* pAnnot) override;
33 CPDFSDK_Annot* NewAnnot(CPDF_Annot* pAnnot, CPDFSDK_PageView* pPage) override;
34 CPDFSDK_Annot* NewAnnot(CXFA_FFWidget* pAnnot,
35 CPDFSDK_PageView* pPage) override;
36 void ReleaseAnnot(CPDFSDK_Annot* pAnnot) override;
37 void DeleteAnnot(CPDFSDK_Annot* pAnnot) override;
38 CFX_FloatRect GetViewBBox(CPDFSDK_PageView* pPageView,
39 CPDFSDK_Annot* pAnnot) override;
40 FX_BOOL HitTest(CPDFSDK_PageView* pPageView,
41 CPDFSDK_Annot* pAnnot,
42 const CFX_FloatPoint& point) override;
43 void OnDraw(CPDFSDK_PageView* pPageView,
44 CPDFSDK_Annot* pAnnot,
45 CFX_RenderDevice* pDevice,
46 CFX_Matrix* pUser2Device,
47 uint32_t dwFlags) override;
48 void OnDrawSleep(CPDFSDK_PageView* pPageView,
49 CPDFSDK_Annot* pAnnot,
50 CFX_RenderDevice* pDevice,
51 CFX_Matrix* pUser2Device,
52 const CFX_FloatRect& rcWindow,
53 uint32_t dwFlags) override;
54 void OnCreate(CPDFSDK_Annot* pAnnot) override;
55 void OnLoad(CPDFSDK_Annot* pAnnot) override;
56 void OnDelete(CPDFSDK_Annot* pAnnot) override;
57 void OnRelease(CPDFSDK_Annot* pAnnot) override;
58 void OnMouseEnter(CPDFSDK_PageView* pPageView,
59 CPDFSDK_Annot* pAnnot,
60 uint32_t nFlag) override;
61 void OnMouseExit(CPDFSDK_PageView* pPageView,
62 CPDFSDK_Annot* pAnnot,
63 uint32_t nFlag) override;
64 FX_BOOL OnLButtonDown(CPDFSDK_PageView* pPageView,
65 CPDFSDK_Annot* pAnnot,
66 uint32_t nFlags,
67 const CFX_FloatPoint& point) override;
68 FX_BOOL OnLButtonUp(CPDFSDK_PageView* pPageView,
69 CPDFSDK_Annot* pAnnot,
70 uint32_t nFlags,
71 const CFX_FloatPoint& point) override;
72 FX_BOOL OnLButtonDblClk(CPDFSDK_PageView* pPageView,
73 CPDFSDK_Annot* pAnnot,
74 uint32_t nFlags,
75 const CFX_FloatPoint& point) override;
76 FX_BOOL OnMouseMove(CPDFSDK_PageView* pPageView,
77 CPDFSDK_Annot* pAnnot,
78 uint32_t nFlags,
79 const CFX_FloatPoint& point) override;
80 FX_BOOL OnMouseWheel(CPDFSDK_PageView* pPageView,
81 CPDFSDK_Annot* pAnnot,
82 uint32_t nFlags,
83 short zDelta,
84 const CFX_FloatPoint& point) override;
85 FX_BOOL OnRButtonDown(CPDFSDK_PageView* pPageView,
86 CPDFSDK_Annot* pAnnot,
87 uint32_t nFlags,
88 const CFX_FloatPoint& point) override;
89 FX_BOOL OnRButtonUp(CPDFSDK_PageView* pPageView,
90 CPDFSDK_Annot* pAnnot,
91 uint32_t nFlags,
92 const CFX_FloatPoint& point) override;
93 FX_BOOL OnRButtonDblClk(CPDFSDK_PageView* pPageView,
94 CPDFSDK_Annot* pAnnot,
95 uint32_t nFlags,
96 const CFX_FloatPoint& point) override;
97 FX_BOOL OnChar(CPDFSDK_Annot* pAnnot,
98 uint32_t nChar,
99 uint32_t nFlags) override;
100 FX_BOOL OnKeyDown(CPDFSDK_Annot* pAnnot, int nKeyCode, int nFlag) override;
101 FX_BOOL OnKeyUp(CPDFSDK_Annot* pAnnot, int nKeyCode, int nFlag) override;
102 void OnDeSelected(CPDFSDK_Annot* pAnnot) override;
103 void OnSelected(CPDFSDK_Annot* pAnnot) override;
104 FX_BOOL OnSetFocus(CPDFSDK_Annot* pAnnot, uint32_t nFlag) override;
105 FX_BOOL OnKillFocus(CPDFSDK_Annot* pAnnot, uint32_t nFlag) override;
106 FX_BOOL OnXFAChangedFocus(CPDFSDK_Annot* pOldAnnot,
107 CPDFSDK_Annot* pNewAnnot) override;
108
109 private:
110 CXFA_FFWidgetHandler* GetXFAWidgetHandler(CPDFSDK_Annot* pAnnot);
111 uint32_t GetFWLFlags(uint32_t dwFlag);
112
113 CPDFDoc_Environment* m_pApp;
114 };
115 #endif // PDF_ENABLE_XFA
116
117 #endif // FPDFSDK_INCLUDE_CPDFSDK_XFAANNOTHANDLER_H_
OLDNEW
« no previous file with comments | « fpdfsdk/include/cpdfsdk_bfannothandler.h ('k') | fpdfsdk/include/fsdk_annothandler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698