fix sdl2 joystick events after joystick closed
See: https://bugzilla.libsdl.org/show_bug.cgi?id=4640
This commit is contained in:
parent
65b77e23ab
commit
57b95ddd3b
1 changed files with 3 additions and 1 deletions
|
@ -1047,7 +1047,7 @@ SDL_JoystickUpdate(void)
|
|||
if (joystick->delayed_guide_button) {
|
||||
SDL_GameControllerHandleDelayedGuideButton(joystick);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if (joystick->force_recentering) {
|
||||
/* Tell the app that everything is centered/unpressed... */
|
||||
|
@ -1067,6 +1067,8 @@ SDL_JoystickUpdate(void)
|
|||
|
||||
joystick->force_recentering = SDL_FALSE;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
SDL_LockJoysticks();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue