Don't switch workspace when reaching the screen edge with mouse if mouse is grabbed by a Window
Hi,
at least in xfwm 4.14.1 in Xubuntu 20.04 the following problem exists: When enabling
- Settings => Window Manager => Advanced => Wrap workspace when reaching the screen edge => [x] With the mouse pointer
the workspace is switched even if an application (like a fullscreen game) has grabbed the mouse cursor (with XGrabPointer()
).
This was reported by a user of the Yamagi Quake II sourceport at https://github.com/yquake2/yquake2/issues/586 and I was able to reproduce it.
Yamagi Quake II calls SDL_SetRelativeMouseMode(SDL_TRUE)
, which calls XGrabPointer()
on X11 (I made sure this succeeds) and also hides the cursor and gets raw mouse input from EVDEV instead of X11. I think the hidden cursor then moves towards the window edge, where it shouldn't do anything as it's supposed to be grabbed by the window - but if it's a fullscreen window that's also the screen edge and XFCE switches workspaces.
TL;DR: Please don't switch the workspace when the mousecursor reaches a screen edge if the cursor is currently grabbed (XGrabPointer()
) by a window.
Cheers,
Daniel