mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-06-06 14:43:20 +00:00
xinput2: correct horizontal touchpad scrolling direction
This fixes testmouse so when fingers move left the green line moves left.
This commit is contained in:
parent
e4f75bac45
commit
5e0f721fd4
1 changed files with 1 additions and 1 deletions
|
|
@ -180,7 +180,7 @@ static void xinput2_parse_scrollable_valuators(const XIDeviceEvent *xev)
|
|||
const double y = info->scroll_type == XIScrollTypeVertical ? delta : 0;
|
||||
|
||||
SDL_Mouse *mouse = SDL_GetMouse();
|
||||
SDL_SendMouseWheel(xev->time, mouse->focus, (SDL_MouseID)xev->sourceid, (float)x, (float)y, SDL_MOUSEWHEEL_NORMAL);
|
||||
SDL_SendMouseWheel(xev->time, mouse->focus, (SDL_MouseID)xev->sourceid, (float)-x, (float)y, SDL_MOUSEWHEEL_NORMAL);
|
||||
}
|
||||
info->prev_value = current_val;
|
||||
info->prev_value_valid = true;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue