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

Side by Side Diff: xfa/fwl/core/fwl_noteimp.h

Issue 1827923002: Move xfa/include/fwl/{core,basewidget} to xfa/fwl/{core,basewidget}. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Rebase to master 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/fwl/core/fwl_gridimp.cpp ('k') | xfa/fwl/core/fwl_noteimp.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 #ifndef XFA_FWL_CORE_FWL_NOTEIMP_H_ 7 #ifndef XFA_FWL_CORE_FWL_NOTEIMP_H_
8 #define XFA_FWL_CORE_FWL_NOTEIMP_H_ 8 #define XFA_FWL_CORE_FWL_NOTEIMP_H_
9 9
10 #include "xfa/include/fwl/core/fwl_note.h" 10 #include "xfa/fwl/core/ifwl_notedriver.h"
11 #include "xfa/fwl/core/ifwl_noteloop.h"
12 #include "xfa/fxgraphics/include/cfx_graphics.h"
11 13
14 class CFWL_CoreToolTipDP;
15 class CFWL_MsgActivate;
16 class CFWL_MsgDeactivate;
17 class CFWL_MsgDropFiles;
18 class CFWL_MsgKey;
19 class CFWL_MsgKillFocus;
20 class CFWL_MsgMouse;
21 class CFWL_MsgMouseWheel;
22 class CFWL_MsgSetFocus;
23 class CFWL_MsgSize;
24 class CFWL_MsgWindowMove;
25 class CFWL_ToolTipImp;
12 class CFWL_WidgetImp; 26 class CFWL_WidgetImp;
13 class CFWL_ToolTipImp; 27 class IFWL_ToolTipTarget;
14 class CFWL_CoreToopTipDP;
15 class CFWL_NoteDriver;
16 class CFWL_EventTarget;
17 class CFWL_ToolTipContainer;
18 28
19 class CFWL_NoteLoop : public IFWL_NoteLoop { 29 class CFWL_NoteLoop : public IFWL_NoteLoop {
20 public: 30 public:
21 CFWL_NoteLoop(CFWL_WidgetImp* pForm = NULL); 31 CFWL_NoteLoop(CFWL_WidgetImp* pForm = NULL);
22 32
23 // IFWL_NoteLoop: 33 // IFWL_NoteLoop:
24 ~CFWL_NoteLoop() override {} 34 ~CFWL_NoteLoop() override {}
25 FX_BOOL PreProcessMessage(CFWL_Message* pMessage) override; 35 FX_BOOL PreProcessMessage(CFWL_Message* pMessage) override;
26 FWL_ERR Idle(int32_t count) override; 36 FWL_ERR Idle(int32_t count) override;
27 37
28 CFWL_WidgetImp* GetForm(); 38 CFWL_WidgetImp* GetForm();
29 FX_BOOL ContinueModal(); 39 FX_BOOL ContinueModal();
30 FWL_ERR EndModalLoop(); 40 FWL_ERR EndModalLoop();
31 FX_BOOL TranslateAccelerator(CFWL_Message* pMessage); 41 FX_BOOL TranslateAccelerator(CFWL_Message* pMessage);
32 FWL_ERR SetMainForm(CFWL_WidgetImp* pForm); 42 FWL_ERR SetMainForm(CFWL_WidgetImp* pForm);
33 43
34 protected: 44 protected:
35 void GenerateCommondEvent(FX_DWORD dwCommand); 45 void GenerateCommondEvent(FX_DWORD dwCommand);
36 46
37 CFWL_WidgetImp* m_pForm; 47 CFWL_WidgetImp* m_pForm;
38 FX_BOOL m_bContinueModal; 48 FX_BOOL m_bContinueModal;
39 }; 49 };
50
40 class CFWL_NoteDriver : public IFWL_NoteDriver { 51 class CFWL_NoteDriver : public IFWL_NoteDriver {
41 public: 52 public:
42 CFWL_NoteDriver(); 53 CFWL_NoteDriver();
43 ~CFWL_NoteDriver() override; 54 ~CFWL_NoteDriver() override;
44 55
45 // IFWL_NoteDriver: 56 // IFWL_NoteDriver:
46 FX_BOOL SendNote(CFWL_Note* pNote) override; 57 FX_BOOL SendNote(CFWL_Note* pNote) override;
47 FX_BOOL PostMessage(CFWL_Message* pMessage) override; 58 FX_BOOL PostMessage(CFWL_Message* pMessage) override;
48 FWL_ERR RegisterEventTarget(IFWL_Widget* pListener, 59 FWL_ERR RegisterEventTarget(IFWL_Widget* pListener,
49 IFWL_Widget* pEventSource = NULL, 60 IFWL_Widget* pEventSource = NULL,
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
98 int32_t m_sendEventCalled; 109 int32_t m_sendEventCalled;
99 int32_t m_maxSize; 110 int32_t m_maxSize;
100 FX_BOOL m_bFullScreen; 111 FX_BOOL m_bFullScreen;
101 IFWL_Widget* m_pHover; 112 IFWL_Widget* m_pHover;
102 IFWL_Widget* m_pFocus; 113 IFWL_Widget* m_pFocus;
103 IFWL_Widget* m_pGrab; 114 IFWL_Widget* m_pGrab;
104 CFWL_NoteLoop* m_pNoteLoop; 115 CFWL_NoteLoop* m_pNoteLoop;
105 FWLMessageHookCallback m_hook; 116 FWLMessageHookCallback m_hook;
106 void* m_hookInfo; 117 void* m_hookInfo;
107 }; 118 };
119
108 typedef CFX_MapPtrTemplate<void*, FX_DWORD> CFWL_EventSource; 120 typedef CFX_MapPtrTemplate<void*, FX_DWORD> CFWL_EventSource;
121
109 class CFWL_EventTarget { 122 class CFWL_EventTarget {
110 public: 123 public:
111 CFWL_EventTarget(CFWL_NoteDriver* pNoteDriver, IFWL_Widget* pListener) 124 CFWL_EventTarget(CFWL_NoteDriver* pNoteDriver, IFWL_Widget* pListener)
112 : m_pListener(pListener), m_pNoteDriver(pNoteDriver), m_bInvalid(FALSE) {} 125 : m_pListener(pListener), m_pNoteDriver(pNoteDriver), m_bInvalid(FALSE) {}
113 ~CFWL_EventTarget(); 126 ~CFWL_EventTarget();
114 int32_t SetEventSource(IFWL_Widget* pSource, 127 int32_t SetEventSource(IFWL_Widget* pSource,
115 FX_DWORD dwFilter = FWL_EVENT_ALL_MASK); 128 FX_DWORD dwFilter = FWL_EVENT_ALL_MASK);
116 FX_BOOL ProcessEvent(CFWL_Event* pEvent); 129 FX_BOOL ProcessEvent(CFWL_Event* pEvent);
117 FX_BOOL IsFilterEvent(CFWL_Event* pEvent, FX_DWORD dwFilter); 130 FX_BOOL IsFilterEvent(CFWL_Event* pEvent, FX_DWORD dwFilter);
118 FX_BOOL IsInvalid() { return m_bInvalid; } 131 FX_BOOL IsInvalid() { return m_bInvalid; }
119 void FlagInvalid() { m_bInvalid = TRUE; } 132 void FlagInvalid() { m_bInvalid = TRUE; }
120 133
121 protected: 134 protected:
122 CFWL_EventSource m_eventSources; 135 CFWL_EventSource m_eventSources;
123 IFWL_Widget* m_pListener; 136 IFWL_Widget* m_pListener;
124 CFWL_NoteDriver* m_pNoteDriver; 137 CFWL_NoteDriver* m_pNoteDriver;
125 FX_BOOL m_bInvalid; 138 FX_BOOL m_bInvalid;
126 }; 139 };
140
127 class CFWL_ToolTipContainer { 141 class CFWL_ToolTipContainer {
128 public: 142 public:
129 static CFWL_ToolTipContainer* getInstance(); 143 static CFWL_ToolTipContainer* getInstance();
130 static void DeleteInstance(); 144 static void DeleteInstance();
131 145
132 FX_ERR AddToolTipTarget(IFWL_ToolTipTarget* pTarget); 146 FX_ERR AddToolTipTarget(IFWL_ToolTipTarget* pTarget);
133 FX_ERR RemoveToolTipTarget(IFWL_ToolTipTarget* pTarget); 147 FX_ERR RemoveToolTipTarget(IFWL_ToolTipTarget* pTarget);
134 IFWL_ToolTipTarget* GetCurrentToolTipTarget(); 148 IFWL_ToolTipTarget* GetCurrentToolTipTarget();
135 149
136 FX_BOOL HasToolTip(IFWL_Widget* pWidget); 150 FX_BOOL HasToolTip(IFWL_Widget* pWidget);
137 151
138 FX_BOOL ProcessEnter(CFWL_EvtMouse* pEvt, IFWL_Widget* pOwner); 152 FX_BOOL ProcessEnter(CFWL_EvtMouse* pEvt, IFWL_Widget* pOwner);
139 FX_BOOL ProcessLeave(CFWL_EvtMouse* pEvt); 153 FX_BOOL ProcessLeave(CFWL_EvtMouse* pEvt);
140 154
141 FX_ERR SetToolTipInitialDelay(int32_t iDelayTime); 155 FX_ERR SetToolTipInitialDelay(int32_t iDelayTime);
142 FX_ERR SetToolTipAutoPopDelay(int32_t iDelayTime); 156 FX_ERR SetToolTipAutoPopDelay(int32_t iDelayTime);
143 157
144 protected: 158 protected:
145 CFWL_ToolTipContainer(); 159 CFWL_ToolTipContainer();
146 virtual ~CFWL_ToolTipContainer(); 160 virtual ~CFWL_ToolTipContainer();
147 161
148 IFWL_ToolTipTarget* pCurTarget; 162 IFWL_ToolTipTarget* pCurTarget;
149 CFWL_ToolTipImp* m_pToolTipImp; 163 CFWL_ToolTipImp* m_pToolTipImp;
150 CFWL_CoreToopTipDP* m_ToolTipDp; 164 CFWL_CoreToolTipDP* m_ToolTipDp;
151 CFX_PtrArray m_arrWidget; 165 CFX_PtrArray m_arrWidget;
152 166
153 private: 167 private:
154 static CFWL_ToolTipContainer* s_pInstance; 168 static CFWL_ToolTipContainer* s_pInstance;
155 }; 169 };
156 170
157 #endif // XFA_FWL_CORE_FWL_NOTEIMP_H_ 171 #endif // XFA_FWL_CORE_FWL_NOTEIMP_H_
OLDNEW
« no previous file with comments | « xfa/fwl/core/fwl_gridimp.cpp ('k') | xfa/fwl/core/fwl_noteimp.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698