mirror of
https://github.com/glfw/glfw.git
synced 2026-09-22 08:50:15 +00:00
Wayland: Fix scroll offsets being inverted
Scrolling offsets were inverted compared to X11 and Win32.
Fixes #1463.
(cherry picked from commit f760b124ca)
This commit is contained in:
committed by
Camilla Löwy
parent
bd2fb9ebaf
commit
114704262c
+2
-2
@@ -347,9 +347,9 @@ static void pointerHandleAxis(void* data,
|
||||
axis == WL_POINTER_AXIS_VERTICAL_SCROLL);
|
||||
|
||||
if (axis == WL_POINTER_AXIS_HORIZONTAL_SCROLL)
|
||||
x = wl_fixed_to_double(value) * scrollFactor;
|
||||
x = -wl_fixed_to_double(value) * scrollFactor;
|
||||
else if (axis == WL_POINTER_AXIS_VERTICAL_SCROLL)
|
||||
y = wl_fixed_to_double(value) * scrollFactor;
|
||||
y = -wl_fixed_to_double(value) * scrollFactor;
|
||||
|
||||
_glfwInputScroll(window, x, y);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user