mirror of
https://github.com/Relintai/sdl2_frt.git
synced 2024-12-16 11:06:49 +01:00
iOS/tvOS: fix support for SDL_GameControllerGetButton(controller, GUIDE) with MFi controllers (thanks Caleb!)
Fixes bug #4463.
This commit is contained in:
parent
e5d194e902
commit
65e07b3884
@ -530,6 +530,7 @@ IOS_MFIJoystickUpdate(SDL_Joystick * joystick)
|
||||
gamepad.buttonX.isPressed, gamepad.buttonY.isPressed,
|
||||
gamepad.leftShoulder.isPressed,
|
||||
gamepad.rightShoulder.isPressed,
|
||||
joystick->delayed_guide_button,
|
||||
};
|
||||
|
||||
hatstate = IOS_MFIJoystickHatStateForDPad(gamepad.dpad);
|
||||
@ -557,6 +558,7 @@ IOS_MFIJoystickUpdate(SDL_Joystick * joystick)
|
||||
gamepad.buttonX.isPressed, gamepad.buttonY.isPressed,
|
||||
gamepad.leftShoulder.isPressed,
|
||||
gamepad.rightShoulder.isPressed,
|
||||
joystick->delayed_guide_button,
|
||||
};
|
||||
|
||||
hatstate = IOS_MFIJoystickHatStateForDPad(gamepad.dpad);
|
||||
@ -583,6 +585,7 @@ IOS_MFIJoystickUpdate(SDL_Joystick * joystick)
|
||||
Uint8 buttons[] = {
|
||||
gamepad.buttonA.isPressed,
|
||||
gamepad.buttonX.isPressed,
|
||||
joystick->delayed_guide_button,
|
||||
};
|
||||
|
||||
for (i = 0; i < SDL_arraysize(buttons); i++) {
|
||||
|
Loading…
Reference in New Issue
Block a user