Skip to content

armgit / zed

Public Imported from GitHub
0

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.

wayland: fix handling of non-discrete scroll events (#9548)

apricotbucket282c36652be2d8
diff --git a/crates/gpui/src/platform/linux/wayland/client.rs b/crates/gpui/src/platform/linux/wayland/client.rs
index 7bb3ebb0f8d..c2a470a48df 100644
--- a/crates/gpui/src/platform/linux/wayland/client.rs
+++ b/crates/gpui/src/platform/linux/wayland/client.rs
@@ -966,8 +966,9 @@ impl Dispatch<wl_pointer::WlPointer, ()> for WaylandClientState {
value,
..
} => {
+ // We handle discrete scroll events with `AxisValue120`.
if wl_pointer.version() >= wl_pointer::EVT_AXIS_VALUE120_SINCE
- && state.axis_source != AxisSource::Continuous
+ && state.axis_source == AxisSource::Wheel
{
return;
}