[client] spice: stop if pointer left during guest warp

This prevents attempts to grab the pointer after the guest side warp
finishes if the pointer has left the window in the meantime. On Wayland,
this would result in the pointer moving to the middle of the window when
the confine is created.
This commit is contained in:
Quantum authored and Geoffrey McRae committed 2021-09-16 06:25:45 +10:00
1 parent 72f3a9f3cf
commit df4a964496
1 file changed
+4
+4
View File
@@ -440,6 +440,10 @@ void core_handleMouseNormal(double ex, double ey)
g_cursor.guest.x = msg.x;
g_cursor.guest.y = msg.y;
g_cursor.realign = false;
if (!g_cursor.inWindow)
return;
core_setCursorInView(true);
return;
}