When starting games or switching to them with Alt-TAB kwin will show a notification about pointer lock. This seems to draw focus from the application window for as long as this notification is shown the game window doesnt receive keyboard events. Real example: I am running Final Fantasy XI under wine. I'm using wine's virtual desktop mode. While the game is running I often switch between the wine window and firefox. Everytime I switch back to wine this notification is shown and I have to wait till it's gone to resume playing. This happens only with wayland.
The window only informs that the application grabbed the pointer. It does not steal any key events.
I have found that the pointer lock and pointer motion notifications using KWin and Wayland will prevent any keyboard input for the three seconds that the notification appears on screen. When I use Vivaldi and either move or resize a window, the pointer motion notification appears and I am unable to input anything using the keyboard within that window until the notification disappears. The mouse reacts fine within the same window during the same period. When I am filling in forms in a new window, it can get tiresome when it repeatedly happens. I have also noticed that this also happened with the video game 7 Days to Die which I have been gifted via Steam.
First of all: I believe you. I just write how the code is supposed to work. Could you please tell me which Qt version you are using?
Hmm I think I found the problem.
I am using Qt 5.9.3.
Possible patch at: https://phabricator.kde.org/D9618 If you have any chance to test this, it would be appreciated. I probably won't have any time to test today or tomorrow.
(In reply to Martin Flöser from comment #3) > First of all: I believe you. I just write how the code is supposed to work. > > Could you please tell me which Qt version you are using? QT 5.10.0 on Arch Linux.
The patch seems to help with my use case. Keyboard input is now possible while the notification is shown. Thank you
Wonderful! Thanks for testing
Git commit f5f1f6ceb49d0d699675a98a8556ff16f9ec9525 by Martin Flöser. Committed on 03/01/2018 at 20:13. Pushed by graesslin into branch 'master'. Don't send keyboard events to QWindows which have outputOnly property set Summary: PlasmaCore.Dialog has a property outputOnly. This is for example used in KWin's OnScreenNotification. If that property is set KWin should not send any key events to it, just like for windows with _q_showWithoutActivating. Test Plan: Not yet Reviewers: #kwin, #plasma Subscribers: plasma-devel, kwin Tags: #plasma Differential Revision: https://phabricator.kde.org/D9618 M +3 -0 input.cpp https://commits.kde.org/kwin/f5f1f6ceb49d0d699675a98a8556ff16f9ec9525