From 2a718fd6c87ec42db59bfef7e28c748ba9d02918 Mon Sep 17 00:00:00 2001 From: SDLBugs Date: Tue, 11 Aug 2020 11:52:06 +0100 Subject: [PATCH] SDL Fix duplicate pad detection on macOS MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- third_party/SDL2-2.0.12/src/joystick/SDL_joystick.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/SDL2-2.0.12/src/joystick/SDL_joystick.c b/SDL2-2.0.12/src/joystick/SDL_joystick.c index 95aac9c6..4c33eee7 100644 --- a/SDL2-2.0.12/src/joystick/SDL_joystick.c +++ b/SDL2-2.0.12/src/joystick/SDL_joystick.c @@ -47,6 +47,9 @@ #endif static SDL_JoystickDriver *SDL_joystick_drivers[] = { +#ifdef SDL_JOYSTICK_HIDAPI + &SDL_HIDAPI_JoystickDriver, +#endif #if defined(SDL_JOYSTICK_DINPUT) || defined(SDL_JOYSTICK_XINPUT) &SDL_WINDOWS_JoystickDriver, #endif @@ -71,9 +74,6 @@ static SDL_JoystickDriver *SDL_joystick_drivers[] = { #ifdef SDL_JOYSTICK_USBHID /* !!! FIXME: "USBHID" is a generic name, and doubly-confusing with HIDAPI next to it. This is the *BSD interface, rename this. */ &SDL_BSD_JoystickDriver, #endif -#ifdef SDL_JOYSTICK_HIDAPI - &SDL_HIDAPI_JoystickDriver, -#endif #if defined(SDL_JOYSTICK_DUMMY) || defined(SDL_JOYSTICK_DISABLED) &SDL_DUMMY_JoystickDriver #endif -- 2.24.1.windows.2