1 // Copyright 2014 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.
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
7 #ifndef PUBLIC_FPDF_FWLEVENT_H_
8 #define PUBLIC_FPDF_FWLEVENT_H_
16 typedef int FPDF_INT32;
17 typedef unsigned int FPDF_UINT32;
18 typedef float FPDF_FLOAT;
22 FWL_EVENTTYPE_Mouse = 0 ,
23 FWL_EVENTTYPE_MouseWheel,
30 FWL_EVENTFLAG_ShiftKey = 1 << 0,
31 FWL_EVENTFLAG_ControlKey = 1 << 1,
32 FWL_EVENTFLAG_AltKey = 1 << 2,
33 FWL_EVENTFLAG_MetaKey = 1 << 3,
34 FWL_EVENTFLAG_KeyPad = 1 << 4,
35 FWL_EVENTFLAG_AutoRepeat = 1 << 5,
36 FWL_EVENTFLAG_LeftButtonDown = 1 << 6,
37 FWL_EVENTFLAG_MiddleButtonDown = 1 << 7,
38 FWL_EVENTFLAG_RightButtonDown = 1 << 8,
41 // Mouse message command
44 FWL_EVENTMOUSECMD_LButtonDown = 1,
45 FWL_EVENTMOUSECMD_LButtonUp,
46 FWL_EVENTMOUSECMD_LButtonDblClk,
47 FWL_EVENTMOUSECMD_RButtonDown,
48 FWL_EVENTMOUSECMD_RButtonUp,
49 FWL_EVENTMOUSECMD_RButtonDblClk,
50 FWL_EVENTMOUSECMD_MButtonDown,
51 FWL_EVENTMOUSECMD_MButtonUp,
52 FWL_EVENTMOUSECMD_MButtonDblClk,
53 FWL_EVENTMOUSECMD_MouseMove,
54 FWL_EVENTMOUSECMD_MouseEnter,
55 FWL_EVENTMOUSECMD_MouseHover,
56 FWL_EVENTMOUSECMD_MouseLeave,
60 struct FWL_EVENT_MOUSE
69 struct FWL_EVENT_MOUSEWHEEL
83 FWL_VKEY_Clear = 0x0C,
84 FWL_VKEY_Return = 0x0D,
85 FWL_VKEY_Shift = 0x10,
86 FWL_VKEY_Control = 0x11,
88 FWL_VKEY_Pause = 0x13,
89 FWL_VKEY_Capital = 0x14,
91 FWL_VKEY_Hangul = 0x15,
92 FWL_VKEY_Junja = 0x17,
93 FWL_VKEY_Final = 0x18,
94 FWL_VKEY_Hanja = 0x19,
95 FWL_VKEY_Kanji = 0x19,
96 FWL_VKEY_Escape = 0x1B,
97 FWL_VKEY_Convert = 0x1C,
98 FWL_VKEY_NonConvert = 0x1D,
99 FWL_VKEY_Accept = 0x1E,
100 FWL_VKEY_ModeChange = 0x1F,
101 FWL_VKEY_Space = 0x20,
102 FWL_VKEY_Prior = 0x21,
103 FWL_VKEY_Next = 0x22,
105 FWL_VKEY_Home = 0x24,
106 FWL_VKEY_Left = 0x25,
108 FWL_VKEY_Right = 0x27,
109 FWL_VKEY_Down = 0x28,
110 FWL_VKEY_Select = 0x29,
111 FWL_VKEY_Print = 0x2A,
112 FWL_VKEY_Execute = 0x2B,
113 FWL_VKEY_Snapshot = 0x2C,
114 FWL_VKEY_Insert = 0x2D,
115 FWL_VKEY_Delete = 0x2E,
116 FWL_VKEY_Help = 0x2F,
153 FWL_VKEY_LWin = 0x5B,
154 FWL_VKEY_Command = 0x5B,
155 FWL_VKEY_RWin = 0x5C,
156 FWL_VKEY_Apps = 0x5D,
157 FWL_VKEY_Sleep = 0x5F,
158 FWL_VKEY_NumPad0 = 0x60,
159 FWL_VKEY_NumPad1 = 0x61,
160 FWL_VKEY_NumPad2 = 0x62,
161 FWL_VKEY_NumPad3 = 0x63,
162 FWL_VKEY_NumPad4 = 0x64,
163 FWL_VKEY_NumPad5 = 0x65,
164 FWL_VKEY_NumPad6 = 0x66,
165 FWL_VKEY_NumPad7 = 0x67,
166 FWL_VKEY_NumPad8 = 0x68,
167 FWL_VKEY_NumPad9 = 0x69,
168 FWL_VKEY_Multiply = 0x6A,
170 FWL_VKEY_Separator = 0x6C,
171 FWL_VKEY_Subtract = 0x6D,
172 FWL_VKEY_Decimal = 0x6E,
173 FWL_VKEY_Divide = 0x6F,
198 FWL_VKEY_NunLock = 0x90,
199 FWL_VKEY_Scroll = 0x91,
200 FWL_VKEY_LShift = 0xA0,
201 FWL_VKEY_RShift = 0xA1,
202 FWL_VKEY_LControl = 0xA2,
203 FWL_VKEY_RControl = 0xA3,
204 FWL_VKEY_LMenu = 0xA4,
205 FWL_VKEY_RMenu = 0xA5,
206 FWL_VKEY_BROWSER_Back = 0xA6,
207 FWL_VKEY_BROWSER_Forward = 0xA7,
208 FWL_VKEY_BROWSER_Refresh = 0xA8,
209 FWL_VKEY_BROWSER_Stop = 0xA9,
210 FWL_VKEY_BROWSER_Search = 0xAA,
211 FWL_VKEY_BROWSER_Favorites = 0xAB,
212 FWL_VKEY_BROWSER_Home = 0xAC,
213 FWL_VKEY_VOLUME_Mute = 0xAD,
214 FWL_VKEY_VOLUME_Down = 0xAE,
215 FWL_VKEY_VOLUME_Up = 0xAF,
216 FWL_VKEY_MEDIA_NEXT_Track = 0xB0,
217 FWL_VKEY_MEDIA_PREV_Track = 0xB1,
218 FWL_VKEY_MEDIA_Stop = 0xB2,
219 FWL_VKEY_MEDIA_PLAY_Pause = 0xB3,
220 FWL_VKEY_MEDIA_LAUNCH_Mail = 0xB4,
221 FWL_VKEY_MEDIA_LAUNCH_MEDIA_Select = 0xB5,
222 FWL_VKEY_MEDIA_LAUNCH_APP1 = 0xB6,
223 FWL_VKEY_MEDIA_LAUNCH_APP2 = 0xB7,
224 FWL_VKEY_OEM_1 = 0xBA,
225 FWL_VKEY_OEM_Plus = 0xBB,
226 FWL_VKEY_OEM_Comma = 0xBC,
227 FWL_VKEY_OEM_Minus = 0xBD,
228 FWL_VKEY_OEM_Period = 0xBE,
229 FWL_VKEY_OEM_2 = 0xBF,
230 FWL_VKEY_OEM_3 = 0xC0,
231 FWL_VKEY_OEM_4 = 0xDB,
232 FWL_VKEY_OEM_5 = 0xDC,
233 FWL_VKEY_OEM_6 = 0xDD,
234 FWL_VKEY_OEM_7 = 0xDE,
235 FWL_VKEY_OEM_8 = 0xDF,
236 FWL_VKEY_OEM_102 = 0xE2,
237 FWL_VKEY_ProcessKey = 0xE5,
238 FWL_VKEY_Packet = 0xE7,
239 FWL_VKEY_Attn = 0xF6,
240 FWL_VKEY_Crsel = 0xF7,
241 FWL_VKEY_Exsel = 0xF8,
242 FWL_VKEY_Ereof = 0xF9,
243 FWL_VKEY_Play = 0xFA,
244 FWL_VKEY_Zoom = 0xFB,
245 FWL_VKEY_NoName = 0xFC,
247 FWL_VKEY_OEM_Clear = 0xFE,
248 FWL_VKEY_Unknown = 0,
254 FWL_EVENTKEYCMD_KeyDown = 1,
255 FWL_EVENTKEYCMD_KeyUp,
256 FWL_EVENTKEYCMD_Char,
282 struct FWL_EVENT_MOUSE mouse;
283 struct FWL_EVENT_MOUSEWHEEL wheel;
284 struct FWL_EVENT_KEY key;
292 #endif // PUBLIC_FPDF_FWLEVENT_H_