mirror of
https://github.com/Relintai/sdl2_frt.git
synced 2024-12-16 11:06:49 +01:00
Wayland: Fixed SDL_GetTouchDevice() returning 0 for the valid device index.
The single touch device gets SDL_TouchID 1 (like on Emscripten, iOS and WinRT).
This commit is contained in:
parent
5d6aa08b28
commit
cd1d7c94e9
@ -88,7 +88,7 @@ touch_handle_touch(void *data,
|
|||||||
uint32_t capabilities = flags >> 16;
|
uint32_t capabilities = flags >> 16;
|
||||||
*/
|
*/
|
||||||
|
|
||||||
SDL_TouchID deviceId = 0;
|
SDL_TouchID deviceId = 1;
|
||||||
if (SDL_AddTouch(deviceId, "qt_touch_extension") < 0) {
|
if (SDL_AddTouch(deviceId, "qt_touch_extension") < 0) {
|
||||||
SDL_Log("error: can't add touch %s, %d", __FILE__, __LINE__);
|
SDL_Log("error: can't add touch %s, %d", __FILE__, __LINE__);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user