https://bugs.winehq.org/show_bug.cgi?id=56073
Bug ID: 56073 Summary: Some Unity games don't receive keyboard input when using virtual desktop Product: Wine Version: 5.12 Hardware: x86-64 OS: Linux Status: UNCONFIRMED Severity: minor Priority: P2 Component: -unknown Assignee: wine-bugs@winehq.org Reporter: random-nick@mail.com Distribution: ---
The issue seems to be absent in 5.11 and present in 5.12. Git bisect resulted in commit 57124b9905bbdedfdd0bca777481d570ffa1769a
Setting UseTakeFocus to N successfully works around the issue, which led me to believe it might be https://bugs.winehq.org/show_bug.cgi?id=48121 but the PoC attached there still works properly in the virtual desktop (and the behaviour without the virtual desktop seems unchanged). I couldn't find a free Unity game which replicates the issue.
https://bugs.winehq.org/show_bug.cgi?id=56073
Olivier F. R. Dierick o.dierick@piezo-forte.be changed:
What |Removed |Added ---------------------------------------------------------------------------- Component|-unknown |wineserver CC| |o.dierick@piezo-forte.be Keywords| |regression Regression SHA1| |57124b9905bbdedfdd0bca77748 | |1d570ffa1769a
--- Comment #1 from Olivier F. R. Dierick o.dierick@piezo-forte.be --- Hello,
Filling some fields for completeness.
--- commit 57124b9905bbdedfdd0bca777481d570ffa1769a --- author Rémi Bernon rbernon@codeweavers.com Wed, 24 Jun 2020 13:28:38 +0000 (15:28 +0200) committer Alexandre Julliard julliard@winehq.org Thu, 25 Jun 2020 21:08:30 +0000 (23:08 +0200)
server: Implement rawinput inter-process message dispatch.
This delivers the rawinput messages to the correct process, regardless of where the input was received.
As for now RIDEV_INPUTSINK is still not implemented, this only fixes the case where input is injected in a background process and where it should not receive rawinput -as in the test- or when cursor moves over a background window and the foreground process should have received rawinput messages. --- end ---
Regards.
https://bugs.winehq.org/show_bug.cgi?id=56073
--- Comment #2 from random-nick@mail.com --- I'm not sure if the bug is actually introduced by the commit or simply the changes triggered it, since it's so similar to the other bug.
https://bugs.winehq.org/show_bug.cgi?id=56073
Vijay Kamuju infyquest@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |infyquest@gmail.com
--- Comment #3 from Vijay Kamuju infyquest@gmail.com --- This is too old version currently not supported, please try with latest RC candidate or version 8
https://bugs.winehq.org/show_bug.cgi?id=56073
--- Comment #4 from random-nick@mail.com --- Created attachment 75777 --> https://bugs.winehq.org/attachment.cgi?id=75777 a test application exhibiting the issue (it should respond to space and enter keys) Part 1/2
7zip archive containing a Unity application which responds to the space and enter keys by changing the displayed text.
It uses the new input system package, since the old input system seems to be unaffected by this issue.
part 1/2
https://bugs.winehq.org/show_bug.cgi?id=56073
--- Comment #5 from random-nick@mail.com --- Created attachment 75778 --> https://bugs.winehq.org/attachment.cgi?id=75778 a test application exhibiting the issue (it should respond to space and enter keys) Part 2/2
part 2/2 of the above archive
https://bugs.winehq.org/show_bug.cgi?id=56073
random-nick@mail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Keywords| |download
--- Comment #6 from random-nick@mail.com --- (In reply to Vijay Kamuju from comment #3)
This is too old version currently not supported, please try with latest RC candidate or version 8
I had already tried with 8.21 and the master at the time when I reported the bug. As for the test application, I tried it on 8.21 and 8.21 staging.
https://bugs.winehq.org/show_bug.cgi?id=56073
Rémi Bernon rbernon@codeweavers.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |rbernon@codeweavers.com
--- Comment #7 from Rémi Bernon rbernon@codeweavers.com --- I don't think the blamed commit is wrong. This is caused however by some bug in our focus / foreground window implementation.
Unity creates a window then shows it with SWP_NOACTIVATE, and later sets focus on it with SetFocus. That SetFocus call is supposed to activate and give foreground to the window process, but this is not implemented in Wine.
We don't implement SWP_NOACTIVATE when window manager is handling the focus, so without the virtual desktop mode, we give foreground to the window as soon as it is shown, and it hides the issue.
This will be very tricky to fix properly, but I think we can have a workaround to set foreground in SetFocus when the desktop window is currently focused, which should address the issues with the Unity games suffering from it as long as the game is started alone in the virtual desktop environment.
https://bugs.winehq.org/show_bug.cgi?id=56073
--- Comment #8 from Rémi Bernon rbernon@codeweavers.com --- Sadly even that simpler workaround fails to pass some tests as shown in https://gitlab.winehq.org/wine/wine/-/merge_requests/4775, so I don't think this will be fixed soon.