aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/input.rs9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/input.rs b/src/input.rs
index cf2c59ba..300577be 100644
--- a/src/input.rs
+++ b/src/input.rs
@@ -701,6 +701,15 @@ impl State {
}
ProximityState::Out => {
tool.proximity_out(event.time_msec());
+
+ // Move the mouse pointer here to avoid discontinuity.
+ //
+ // Plus, Wayland SDL2 currently warps the pointer into some weird
+ // location on proximity out, so this shuold help it a little.
+ if let Some(pos) = self.niri.tablet_cursor_location {
+ self.move_cursor(pos);
+ }
+
self.niri.tablet_cursor_location = None;
}
}