@@ -175,6 +175,8 @@ typedef enum SDL_EventType
175
175
SDL_EVENT_KEYBOARD_ADDED , /**< A new keyboard has been inserted into the system */
176
176
SDL_EVENT_KEYBOARD_REMOVED , /**< A keyboard has been removed */
177
177
SDL_EVENT_TEXT_EDITING_CANDIDATES , /**< Keyboard text editing candidates */
178
+ SDL_EVENT_KEYBOARD_FIRST = SDL_EVENT_KEY_DOWN ,
179
+ SDL_EVENT_KEYBOARD_LAST = SDL_EVENT_TEXT_EDITING_CANDIDATES ,
178
180
179
181
/* Mouse events */
180
182
SDL_EVENT_MOUSE_MOTION = 0x400 , /**< Mouse moved */
@@ -183,6 +185,8 @@ typedef enum SDL_EventType
183
185
SDL_EVENT_MOUSE_WHEEL , /**< Mouse wheel motion */
184
186
SDL_EVENT_MOUSE_ADDED , /**< A new mouse has been inserted into the system */
185
187
SDL_EVENT_MOUSE_REMOVED , /**< A mouse has been removed */
188
+ SDL_EVENT_MOUSE_FIRST = SDL_EVENT_MOUSE_MOTION ,
189
+ SDL_EVENT_MOUSE_LAST = SDL_EVENT_MOUSE_REMOVED ,
186
190
187
191
/* Joystick events */
188
192
SDL_EVENT_JOYSTICK_AXIS_MOTION = 0x600 , /**< Joystick axis motion */
@@ -194,6 +198,8 @@ typedef enum SDL_EventType
194
198
SDL_EVENT_JOYSTICK_REMOVED , /**< An opened joystick has been removed */
195
199
SDL_EVENT_JOYSTICK_BATTERY_UPDATED , /**< Joystick battery level change */
196
200
SDL_EVENT_JOYSTICK_UPDATE_COMPLETE , /**< Joystick update is complete */
201
+ SDL_EVENT_JOYSTICK_FIRST = SDL_EVENT_JOYSTICK_AXIS_MOTION ,
202
+ SDL_EVENT_JOYSTICK_LAST = SDL_EVENT_JOYSTICK_UPDATE_COMPLETE ,
197
203
198
204
/* Gamepad events */
199
205
SDL_EVENT_GAMEPAD_AXIS_MOTION = 0x650 , /**< Gamepad axis motion */
@@ -208,12 +214,16 @@ typedef enum SDL_EventType
208
214
SDL_EVENT_GAMEPAD_SENSOR_UPDATE , /**< Gamepad sensor was updated */
209
215
SDL_EVENT_GAMEPAD_UPDATE_COMPLETE , /**< Gamepad update is complete */
210
216
SDL_EVENT_GAMEPAD_STEAM_HANDLE_UPDATED , /**< Gamepad Steam handle has changed */
217
+ SDL_EVENT_GAMEPAD_FIRST = SDL_EVENT_GAMEPAD_AXIS_MOTION ,
218
+ SDL_EVENT_GAMEPAD_LAST = SDL_EVENT_GAMEPAD_STEAM_HANDLE_UPDATED ,
211
219
212
220
/* Touch events */
213
221
SDL_EVENT_FINGER_DOWN = 0x700 ,
214
222
SDL_EVENT_FINGER_UP ,
215
223
SDL_EVENT_FINGER_MOTION ,
216
224
SDL_EVENT_FINGER_CANCELED ,
225
+ SDL_EVENT_FINGER_FIRST = SDL_EVENT_FINGER_DOWN ,
226
+ SDL_EVENT_FINGER_LAST = SDL_EVENT_FINGER_CANCELLED ,
217
227
218
228
/* 0x800, 0x801, and 0x802 were the Gesture events from SDL2. Do not reuse these values! sdl2-compat needs them! */
219
229
@@ -226,11 +236,15 @@ typedef enum SDL_EventType
226
236
SDL_EVENT_DROP_BEGIN , /**< A new set of drops is beginning (NULL filename) */
227
237
SDL_EVENT_DROP_COMPLETE , /**< Current set of drops is now complete (NULL filename) */
228
238
SDL_EVENT_DROP_POSITION , /**< Position while moving over the window */
239
+ SDL_EVENT_DROP_FIRST = SDL_EVENT_DROP_FILE ,
240
+ SDL_EVENT_DROP_LAST = SDL_EVENT_DROP_POSITION ,
229
241
230
242
/* Audio hotplug events */
231
243
SDL_EVENT_AUDIO_DEVICE_ADDED = 0x1100 , /**< A new audio device is available */
232
244
SDL_EVENT_AUDIO_DEVICE_REMOVED , /**< An audio device has been removed. */
233
245
SDL_EVENT_AUDIO_DEVICE_FORMAT_CHANGED , /**< An audio device's format has been changed by the system. */
246
+ SDL_EVENT_AUDIO_FIRST = SDL_EVENT_AUDIO_DEVICE_ADDED ,
247
+ SDL_EVENT_AUDIO_LAST = SDL_EVENT_AUDIO_DEVICE_FORMAT_CHANGED ,
234
248
235
249
/* Sensor events */
236
250
SDL_EVENT_SENSOR_UPDATE = 0x1200 , /**< A sensor was updated */
@@ -244,17 +258,24 @@ typedef enum SDL_EventType
244
258
SDL_EVENT_PEN_BUTTON_UP , /**< Pressure-sensitive pen button released */
245
259
SDL_EVENT_PEN_MOTION , /**< Pressure-sensitive pen is moving on the tablet */
246
260
SDL_EVENT_PEN_AXIS , /**< Pressure-sensitive pen angle/pressure/etc changed */
261
+ SDL_EVENT_PEN_FIRST = SDL_EVENT_PEN_PROXIMITY_IN ,
262
+ SDL_EVENT_PEN_LAST = SDL_EVENT_PEN_AXIS ,
247
263
248
264
/* Camera hotplug events */
249
265
SDL_EVENT_CAMERA_DEVICE_ADDED = 0x1400 , /**< A new camera device is available */
250
266
SDL_EVENT_CAMERA_DEVICE_REMOVED , /**< A camera device has been removed. */
251
267
SDL_EVENT_CAMERA_DEVICE_APPROVED , /**< A camera device has been approved for use by the user. */
252
268
SDL_EVENT_CAMERA_DEVICE_DENIED , /**< A camera device has been denied for use by the user. */
269
+ SDL_EVENT_CAMERA_FIRST = SDL_EVENT_CAMERA_DEVICE_ADDED ,
270
+ SDL_EVENT_CAMERA_LAST = SDL_EVENT_CAMERA_DEVICE_DENIED ,
253
271
254
272
/* Render events */
255
273
SDL_EVENT_RENDER_TARGETS_RESET = 0x2000 , /**< The render targets have been reset and their contents need to be updated */
256
274
SDL_EVENT_RENDER_DEVICE_RESET , /**< The device has been reset and all textures need to be recreated */
257
275
SDL_EVENT_RENDER_DEVICE_LOST , /**< The device has been lost and can't be recovered. */
276
+ SDL_EVENT_RENDER_FIRST = SDL_EVENT_RENDER_TARGETS_RESET ,
277
+ SDL_EVENT_RENDER_LAST = SDL_EVENT_RENDER_DEVICE_LOST ,
278
+
258
279
259
280
/* Reserved events for private platforms */
260
281
SDL_EVENT_PRIVATE0 = 0x4000 ,
0 commit comments