From efdb390caa1b3f9b0cd8370d7ce0eb4301b8055c Mon Sep 17 00:00:00 2001 From: Sam Lantinga Date: Sun, 9 Oct 2022 09:11:33 -0700 Subject: [PATCH] Disable the HIDAPI Wii driver by default as it doesn't work with the dolphinbar --- include/SDL_hints.h | 2 +- src/joystick/hidapi/SDL_hidapi_wii.c | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/include/SDL_hints.h b/include/SDL_hints.h index b387118be..4d445b35c 100644 --- a/include/SDL_hints.h +++ b/include/SDL_hints.h @@ -872,7 +872,7 @@ extern "C" { * "0" - HIDAPI driver is not used * "1" - HIDAPI driver is used * - * The default is the value of SDL_HINT_JOYSTICK_HIDAPI + * This driver doesn't work with the dolphinbar, so the default is SDL_FALSE for now. */ #define SDL_HINT_JOYSTICK_HIDAPI_WII "SDL_JOYSTICK_HIDAPI_WII" diff --git a/src/joystick/hidapi/SDL_hidapi_wii.c b/src/joystick/hidapi/SDL_hidapi_wii.c index 3f40fcc44..3b4e79411 100644 --- a/src/joystick/hidapi/SDL_hidapi_wii.c +++ b/src/joystick/hidapi/SDL_hidapi_wii.c @@ -170,9 +170,13 @@ HIDAPI_DriverWii_UnregisterHints(SDL_HintCallback callback, void *userdata) static SDL_bool HIDAPI_DriverWii_IsEnabled(void) { +#if 1 /* This doesn't work with the dolphinbar, so don't enable by default right now */ + return SDL_GetHintBoolean(SDL_HINT_JOYSTICK_HIDAPI_WII, SDL_FALSE); +#else return SDL_GetHintBoolean(SDL_HINT_JOYSTICK_HIDAPI_WII, SDL_GetHintBoolean(SDL_HINT_JOYSTICK_HIDAPI, SDL_HIDAPI_DEFAULT)); +#endif } static SDL_bool