Fix horizontal scrolling direction on Windows (#11520)

As per Microsoft documentation, positive values scroll right, not left.
GPUI was incorrectly assuming it perfectly mirrored vertical scrolling.

Fixes #11515

Release Notes:

- N/A
This commit is contained in:
LoganDark 2024-05-08 10:56:31 -07:00 committed by GitHub
parent 0933426e63
commit 91c1716858
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -547,7 +547,7 @@ fn handle_mouse_horizontal_wheel_msg(
let wheel_scroll_chars = lock.mouse_wheel_settings.wheel_scroll_chars;
drop(lock);
let wheel_distance =
(wparam.signed_hiword() as f32 / WHEEL_DELTA as f32) * wheel_scroll_chars as f32;
(-wparam.signed_hiword() as f32 / WHEEL_DELTA as f32) * wheel_scroll_chars as f32;
let mut cursor_point = POINT {
x: lparam.signed_loword().into(),
y: lparam.signed_hiword().into(),