hidclass.sys: Make sure a desktop is created for the driver process.

This was previously automatically done when user32 was loaded, but since
the move of __wine_send_input to win32u, we do not need to load it any
more. Make sure we have a desktop or WM_INPUT messages won't be sent by
wineserver.
This commit is contained in:
Rémi Bernon 2022-12-19 11:39:38 +01:00 committed by Alexandre Julliard
parent c28258039b
commit 5225aabd07

View file

@ -599,6 +599,10 @@ NTSTATUS WINAPI HidRegisterMinidriver(HID_MINIDRIVER_REGISTRATION *registration)
{
minidriver *driver;
/* make sure we have a window station and a desktop, we need one to send input */
if (!GetProcessWindowStation())
return STATUS_INVALID_PARAMETER;
if (!(driver = calloc(1, sizeof(*driver))))
return STATUS_NO_MEMORY;