Mouse / Keyboard input not captured on wine

Hi,

There is an issue with Wine, where sometimes it doesn’t capture the mouse after opening a game.

I found others with the same problem.

https://www.reddit.com/r/kde/comments/hf33zm/help_mouse_is_confined_to_game_window_cannot_get/

A fix for that were unchecking Allow the windows manager to control the windows. This helped, even seem to have made animations smoother ingame.

Whoever if all are working and I minimize (alt+tab) the game, there is no option to go back other than a small black square, but if I click on it, it goes back to the game, not a big problem here.

The main problem are, sometimes after coming back, the keyboard input does not work anymore, not even to exit the game. I have to cause it to trigger to shutdown/restart the system, then cancel the behavior, by that point the game has closed and steam is closing.

I wanted to ask if anyone had the problem and perhaps found a solution?


It’s a similar problem / behavior when enabling wayland on proton with PROTON_ENABLE_WAYLAND=1


Once you are able to get back into the game, after pressing the black box, it is stuck there with no keyboard input.


By having a second monitor on, it helps changing window focus to be able to do something with the mouse and keyboard. But keyboard input still does not work in-game.


I made the changes with protontricks game-id winecfg


Randomly, the fps stay on 20fps~, sometimes I have to turn the screen into borderless or fullscreen to fix. Multiple times.


Seems related though I am currently using gnome. Mouse not locking in Wine/Proton programs in fullscreen or windowed · Issue #2376 · hyprwm/Hyprland · GitHub

And Caffe 7.18 Fullscreen Mouse Bug in Overwatch 2 · Issue #870 · Frogging-Family/wine-tkg-git · GitHub


Not sure if these patches has anything related wine-tkg-git/wine-tkg-git/wine-tkg-patches/proton-tkg-specific/proton-sdl-joy at master · Frogging-Family/wine-tkg-git · GitHub