Some few 3D games are very hard to work well with the mouse grab.
Sometimes even with winecfg force grab on full screen checked, and the regedit key MouseWarpOverride set to force, it may still not work well.
So, what can be done to really force the mouse pointer to be grabbed or re-grabbed?


First you have to force ungrab the mouse with:
setxkbmap -option grab:break_actions;xdotool key XF86Ungrab I bound it with xbindkeys (but read this about security https://unix.stackexchange.com/a/62255/235896)
now, click on the title bar of the game window and it should force re-grab properly.

If it doesn't work, try toggle the application between full screen and windowed mode, and try to ungrab again and click on the title bar. The title bar may have to be the linux one or the windows one (in case your are emulating a windows desktop), try on both.

I couldn't determine yet the right steps that always work at once, when I find it I edit here again.

This (may require some tries) but works on Ubuntu 18.04 with Wine 5.8 at least.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.