git.lucas.co / cce-compositor
Wayland compositor (wlroots)
git clone https://git.lucas.co/cce-compositor.git

commit86baf0d7975fb8a57f46ea8a490b9ed62e1136b1
parent2207419f7b
authorIsaac Freund <[email protected]>
date2023-03-14 12:07
Cursor: fix warp on output change with no views

 river/Seat.zig | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/river/Seat.zig b/river/Seat.zig
index 5b5075f..ef561b1 100644
--- a/river/Seat.zig
+++ b/river/Seat.zig
@@ -327,6 +327,10 @@ pub fn focusOutput(self: *Self, output: ?*Output) void {
         var it = self.status_trackers.first;
         while (it) |node| : (it = node.next) node.data.sendOutput(new, .focused);
     }
+
+    // Depending on configuration and cursor position, changing output focus
+    // may cause the cursor to be warped.
+    self.cursor.may_need_warp = true;
 }
 
 pub fn handleActivity(self: Self) void {