Added support for the Power A Nintendo Switch Enhanced Wireless Controller

This commit is contained in:
Sam Lantinga
2019-10-22 10:57:07 -07:00
parent f96da11f93
commit 9da4bfc141
11 changed files with 37 additions and 21 deletions

View File

@@ -535,7 +535,7 @@ EnumJoysticksCallback(const DIDEVICEINSTANCE * pdidInstance, VOID * pContext)
}
#ifdef SDL_JOYSTICK_HIDAPI
if (HIDAPI_IsDevicePresent(vendor, product, 0)) {
if (HIDAPI_IsDevicePresent(vendor, product, 0, pNewJoystick->joystickname)) {
/* The HIDAPI driver is taking care of this device */
SDL_free(pNewJoystick);
return DIENUM_CONTINUE;