mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-10-20 00:31:44 +00:00
SDL
- detect that you tried to open a gamecontroller in xinput mode and failed, then re-get the mapping for the dinput variant you did open (and most likely now just fail the open) CR: SamL
This commit is contained in:
@@ -1776,6 +1776,12 @@ SDL_bool SDL_SYS_IsXInputDeviceIndex(int device_index)
|
||||
return device->bXInputDevice;
|
||||
}
|
||||
|
||||
/* return SDL_TRUE if this device was opened with XInput */
|
||||
SDL_bool SDL_SYS_IsXInputJoystick(SDL_Joystick * joystick)
|
||||
{
|
||||
return joystick->hwdata->bXInputDevice;
|
||||
}
|
||||
|
||||
#endif /* SDL_JOYSTICK_DINPUT */
|
||||
|
||||
/* vi: set ts=4 sw=4 expandtab: */
|
||||
|
Reference in New Issue
Block a user