Updated Haptic API for SDL 3.0 conventions

Also removed the XInput haptic support since using the haptic API for rumble is no longer supported.
This commit is contained in:
Sam Lantinga
2024-01-17 15:22:35 -08:00
parent 8ca9134115
commit f224af5ac5
35 changed files with 943 additions and 1320 deletions

View File

@@ -1981,19 +1981,11 @@ elseif(WINDOWS)
set(HAVE_SDL_JOYSTICK TRUE)
if(SDL_HAPTIC)
if((HAVE_DINPUT_H OR HAVE_XINPUT_H) AND NOT WINDOWS_STORE)
if(HAVE_DINPUT_H AND NOT WINDOWS_STORE)
sdl_glob_sources("${SDL3_SOURCE_DIR}/src/haptic/windows/*.c")
if(HAVE_DINPUT_H)
set(SDL_HAPTIC_DINPUT 1)
endif()
if(HAVE_XINPUT_H)
set(SDL_HAPTIC_XINPUT 1)
endif()
else()
sdl_glob_sources("${SDL3_SOURCE_DIR}/src/haptic/dummy/*.c")
set(SDL_HAPTIC_DUMMY 1)
set(SDL_HAPTIC_DINPUT 1)
set(HAVE_SDL_HAPTIC TRUE)
endif()
set(HAVE_SDL_HAPTIC TRUE)
endif()
endif()