Fill the correct member with the joystick ID in SDL_EVENT_JOYSTICK_UPDATE_COMPLETE

This commit is contained in:
Sam Lantinga committed 2023-08-08 09:47:49 -07:00
1 parent 55cf1abaa6
commit 463c456b98
1 file changed
+1 -1
+1 -1
View File
@@ -1953,7 +1953,7 @@ void SDL_UpdateJoysticks(void)
event.type = SDL_EVENT_JOYSTICK_UPDATE_COMPLETE;
event.common.timestamp = joystick->update_complete;
event.gdevice.which = joystick->instance_id;
event.jdevice.which = joystick->instance_id;
SDL_PushEvent(&event);
joystick->update_complete = 0;