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

Side by Side Diff: xfa/fxfa/app/xfa_ffwidget.h

Issue 1835703002: Remove FX_DWORD from XFA, part 2 (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 4 years, 9 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 | « xfa/fxfa/app/xfa_fftextedit.h ('k') | xfa/fxfa/app/xfa_ffwidgethandler.h » ('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 #ifndef XFA_FXFA_APP_XFA_FFWIDGET_H_ 7 #ifndef XFA_FXFA_APP_XFA_FFWIDGET_H_
8 #define XFA_FXFA_APP_XFA_FFWIDGET_H_ 8 #define XFA_FXFA_APP_XFA_FFWIDGET_H_
9 9
10 #include <vector> 10 #include <vector>
(...skipping 28 matching lines...) Expand all
39 class CXFA_FFWidget : public IXFA_Widget, 39 class CXFA_FFWidget : public IXFA_Widget,
40 public CFX_PrivateData, 40 public CFX_PrivateData,
41 public CXFA_ContentLayoutItem { 41 public CXFA_ContentLayoutItem {
42 public: 42 public:
43 CXFA_FFWidget(CXFA_FFPageView* pPageView, CXFA_WidgetAcc* pDataAcc); 43 CXFA_FFWidget(CXFA_FFPageView* pPageView, CXFA_WidgetAcc* pDataAcc);
44 virtual ~CXFA_FFWidget(); 44 virtual ~CXFA_FFWidget();
45 IXFA_PageView* GetPageView(); 45 IXFA_PageView* GetPageView();
46 void SetPageView(IXFA_PageView* pPageView); 46 void SetPageView(IXFA_PageView* pPageView);
47 void GetWidgetRect(CFX_RectF& rtWidget); 47 void GetWidgetRect(CFX_RectF& rtWidget);
48 CFX_RectF ReCacheWidgetRect(); 48 CFX_RectF ReCacheWidgetRect();
49 FX_DWORD GetStatus(); 49 uint32_t GetStatus();
50 void ModifyStatus(FX_DWORD dwAdded, FX_DWORD dwRemoved); 50 void ModifyStatus(uint32_t dwAdded, uint32_t dwRemoved);
51 virtual FX_BOOL GetBBox(CFX_RectF& rtBox, 51 virtual FX_BOOL GetBBox(CFX_RectF& rtBox,
52 FX_DWORD dwStatus, 52 uint32_t dwStatus,
53 FX_BOOL bDrawFocus = FALSE); 53 FX_BOOL bDrawFocus = FALSE);
54 CXFA_WidgetAcc* GetDataAcc(); 54 CXFA_WidgetAcc* GetDataAcc();
55 FX_BOOL GetToolTip(CFX_WideString& wsToolTip); 55 FX_BOOL GetToolTip(CFX_WideString& wsToolTip);
56 virtual void RenderWidget(CFX_Graphics* pGS, 56 virtual void RenderWidget(CFX_Graphics* pGS,
57 CFX_Matrix* pMatrix = NULL, 57 CFX_Matrix* pMatrix = NULL,
58 FX_DWORD dwStatus = 0, 58 uint32_t dwStatus = 0,
59 int32_t iRotate = 0); 59 int32_t iRotate = 0);
60 60
61 virtual FX_BOOL IsLoaded(); 61 virtual FX_BOOL IsLoaded();
62 virtual FX_BOOL LoadWidget(); 62 virtual FX_BOOL LoadWidget();
63 virtual void UnloadWidget(); 63 virtual void UnloadWidget();
64 virtual FX_BOOL PerformLayout(); 64 virtual FX_BOOL PerformLayout();
65 virtual FX_BOOL UpdateFWLData(); 65 virtual FX_BOOL UpdateFWLData();
66 virtual void UpdateWidgetProperty(); 66 virtual void UpdateWidgetProperty();
67 virtual FX_BOOL OnMouseEnter(); 67 virtual FX_BOOL OnMouseEnter();
68 virtual FX_BOOL OnMouseExit(); 68 virtual FX_BOOL OnMouseExit();
69 virtual FX_BOOL OnLButtonDown(FX_DWORD dwFlags, FX_FLOAT fx, FX_FLOAT fy); 69 virtual FX_BOOL OnLButtonDown(uint32_t dwFlags, FX_FLOAT fx, FX_FLOAT fy);
70 virtual FX_BOOL OnLButtonUp(FX_DWORD dwFlags, FX_FLOAT fx, FX_FLOAT fy); 70 virtual FX_BOOL OnLButtonUp(uint32_t dwFlags, FX_FLOAT fx, FX_FLOAT fy);
71 virtual FX_BOOL OnLButtonDblClk(FX_DWORD dwFlags, FX_FLOAT fx, FX_FLOAT fy); 71 virtual FX_BOOL OnLButtonDblClk(uint32_t dwFlags, FX_FLOAT fx, FX_FLOAT fy);
72 virtual FX_BOOL OnMouseMove(FX_DWORD dwFlags, FX_FLOAT fx, FX_FLOAT fy); 72 virtual FX_BOOL OnMouseMove(uint32_t dwFlags, FX_FLOAT fx, FX_FLOAT fy);
73 virtual FX_BOOL OnMouseWheel(FX_DWORD dwFlags, 73 virtual FX_BOOL OnMouseWheel(uint32_t dwFlags,
74 int16_t zDelta, 74 int16_t zDelta,
75 FX_FLOAT fx, 75 FX_FLOAT fx,
76 FX_FLOAT fy); 76 FX_FLOAT fy);
77 virtual FX_BOOL OnRButtonDown(FX_DWORD dwFlags, FX_FLOAT fx, FX_FLOAT fy); 77 virtual FX_BOOL OnRButtonDown(uint32_t dwFlags, FX_FLOAT fx, FX_FLOAT fy);
78 virtual FX_BOOL OnRButtonUp(FX_DWORD dwFlags, FX_FLOAT fx, FX_FLOAT fy); 78 virtual FX_BOOL OnRButtonUp(uint32_t dwFlags, FX_FLOAT fx, FX_FLOAT fy);
79 virtual FX_BOOL OnRButtonDblClk(FX_DWORD dwFlags, FX_FLOAT fx, FX_FLOAT fy); 79 virtual FX_BOOL OnRButtonDblClk(uint32_t dwFlags, FX_FLOAT fx, FX_FLOAT fy);
80 80
81 virtual FX_BOOL OnSetFocus(CXFA_FFWidget* pOldWidget); 81 virtual FX_BOOL OnSetFocus(CXFA_FFWidget* pOldWidget);
82 virtual FX_BOOL OnKillFocus(CXFA_FFWidget* pNewWidget); 82 virtual FX_BOOL OnKillFocus(CXFA_FFWidget* pNewWidget);
83 virtual FX_BOOL OnKeyDown(FX_DWORD dwKeyCode, FX_DWORD dwFlags); 83 virtual FX_BOOL OnKeyDown(uint32_t dwKeyCode, uint32_t dwFlags);
84 virtual FX_BOOL OnKeyUp(FX_DWORD dwKeyCode, FX_DWORD dwFlags); 84 virtual FX_BOOL OnKeyUp(uint32_t dwKeyCode, uint32_t dwFlags);
85 virtual FX_BOOL OnChar(FX_DWORD dwChar, FX_DWORD dwFlags); 85 virtual FX_BOOL OnChar(uint32_t dwChar, uint32_t dwFlags);
86 virtual FX_DWORD OnHitTest(FX_FLOAT fx, FX_FLOAT fy); 86 virtual uint32_t OnHitTest(FX_FLOAT fx, FX_FLOAT fy);
87 virtual FX_BOOL OnSetCursor(FX_FLOAT fx, FX_FLOAT fy); 87 virtual FX_BOOL OnSetCursor(FX_FLOAT fx, FX_FLOAT fy);
88 virtual FX_BOOL CanUndo() { return FALSE; } 88 virtual FX_BOOL CanUndo() { return FALSE; }
89 virtual FX_BOOL CanRedo() { return FALSE; } 89 virtual FX_BOOL CanRedo() { return FALSE; }
90 virtual FX_BOOL Undo() { return FALSE; } 90 virtual FX_BOOL Undo() { return FALSE; }
91 virtual FX_BOOL Redo() { return FALSE; } 91 virtual FX_BOOL Redo() { return FALSE; }
92 virtual FX_BOOL CanCopy() { return FALSE; } 92 virtual FX_BOOL CanCopy() { return FALSE; }
93 virtual FX_BOOL CanCut() { return FALSE; } 93 virtual FX_BOOL CanCut() { return FALSE; }
94 virtual FX_BOOL CanPaste() { return FALSE; } 94 virtual FX_BOOL CanPaste() { return FALSE; }
95 virtual FX_BOOL CanSelectAll() { return FALSE; } 95 virtual FX_BOOL CanSelectAll() { return FALSE; }
96 virtual FX_BOOL CanDelete() { return CanCut(); } 96 virtual FX_BOOL CanDelete() { return CanCut(); }
(...skipping 26 matching lines...) Expand all
123 FX_BOOL IsLayoutRectEmpty(); 123 FX_BOOL IsLayoutRectEmpty();
124 CXFA_FFWidget* GetParent(); 124 CXFA_FFWidget* GetParent();
125 FX_BOOL IsAncestorOf(CXFA_FFWidget* pWidget); 125 FX_BOOL IsAncestorOf(CXFA_FFWidget* pWidget);
126 126
127 protected: 127 protected:
128 virtual FX_BOOL PtInActiveRect(FX_FLOAT fx, FX_FLOAT fy); 128 virtual FX_BOOL PtInActiveRect(FX_FLOAT fx, FX_FLOAT fy);
129 void DrawBorder(CFX_Graphics* pGS, 129 void DrawBorder(CFX_Graphics* pGS,
130 CXFA_Box box, 130 CXFA_Box box,
131 const CFX_RectF& rtBorder, 131 const CFX_RectF& rtBorder,
132 CFX_Matrix* pMatrix, 132 CFX_Matrix* pMatrix,
133 FX_DWORD dwFlags = 0); 133 uint32_t dwFlags = 0);
134 void GetMinMaxWidth(FX_FLOAT fMinWidth, FX_FLOAT fMaxWidth); 134 void GetMinMaxWidth(FX_FLOAT fMinWidth, FX_FLOAT fMaxWidth);
135 void GetMinMaxHeight(FX_FLOAT fMinHeight, FX_FLOAT fMaxHeight); 135 void GetMinMaxHeight(FX_FLOAT fMinHeight, FX_FLOAT fMaxHeight);
136 void GetRectWithoutRotate(CFX_RectF& rtWidget); 136 void GetRectWithoutRotate(CFX_RectF& rtWidget);
137 FX_BOOL IsMatchVisibleStatus(FX_DWORD dwStatus); 137 FX_BOOL IsMatchVisibleStatus(uint32_t dwStatus);
138 138
139 void EventKillFocus(); 139 void EventKillFocus();
140 FX_BOOL IsButtonDown(); 140 FX_BOOL IsButtonDown();
141 void SetButtonDown(FX_BOOL bSet); 141 void SetButtonDown(FX_BOOL bSet);
142 CXFA_FFDocView* m_pDocView; 142 CXFA_FFDocView* m_pDocView;
143 CXFA_FFPageView* m_pPageView; 143 CXFA_FFPageView* m_pPageView;
144 CXFA_WidgetAcc* m_pDataAcc; 144 CXFA_WidgetAcc* m_pDataAcc;
145 CFX_RectF m_rtWidget; 145 CFX_RectF m_rtWidget;
146 }; 146 };
147 int32_t XFA_StrokeTypeSetLineDash(CFX_Graphics* pGraphics, 147 int32_t XFA_StrokeTypeSetLineDash(CFX_Graphics* pGraphics,
(...skipping 27 matching lines...) Expand all
175 FX_BOOL b3DStyle, 175 FX_BOOL b3DStyle,
176 int32_t nIndex); 176 int32_t nIndex);
177 CXFA_FFWidget* XFA_GetWidgetFromLayoutItem(CXFA_LayoutItem* pLayoutItem); 177 CXFA_FFWidget* XFA_GetWidgetFromLayoutItem(CXFA_LayoutItem* pLayoutItem);
178 FX_BOOL XFA_IsCreateWidget(XFA_ELEMENT iType); 178 FX_BOOL XFA_IsCreateWidget(XFA_ELEMENT iType);
179 #define XFA_DRAWBOX_ForceRound 1 179 #define XFA_DRAWBOX_ForceRound 1
180 #define XFA_DRAWBOX_Lowered3D 2 180 #define XFA_DRAWBOX_Lowered3D 2
181 void XFA_DrawBox(CXFA_Box box, 181 void XFA_DrawBox(CXFA_Box box,
182 CFX_Graphics* pGS, 182 CFX_Graphics* pGS,
183 const CFX_RectF& rtWidget, 183 const CFX_RectF& rtWidget,
184 CFX_Matrix* pMatrix, 184 CFX_Matrix* pMatrix,
185 FX_DWORD dwFlags = 0); 185 uint32_t dwFlags = 0);
186 186
187 #endif // XFA_FXFA_APP_XFA_FFWIDGET_H_ 187 #endif // XFA_FXFA_APP_XFA_FFWIDGET_H_
OLDNEW
« no previous file with comments | « xfa/fxfa/app/xfa_fftextedit.h ('k') | xfa/fxfa/app/xfa_ffwidgethandler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698