1
0
mirror of https://github.com/RPCS3/rpcs3.git synced 2024-11-22 10:42:36 +01:00

SDL: Fix button presses

SDL currently always returns 1 if a button is pressed
This commit is contained in:
Megamouse 2023-02-03 18:03:19 +01:00
parent c5b25fa132
commit d69e345bc0

View File

@ -783,7 +783,9 @@ std::unordered_map<u64, u16> sdl_pad_handler::get_button_values(const std::share
{
const u8 value = SDL_GameControllerGetButton(dev->sdl.game_controller, button_id);
const SDLKeyCodes key_code = get_button_code(button_id);
values[key_code] = value;
// TODO: SDL does not support DS3 button intensity in the current version
values[key_code] = value ? 255 : 0;
}
for (SDL_GameControllerAxis axis_id : dev->sdl.axis_ids)