Rémi Bernon (@rbernon) commented about dlls/winewayland.drv/display.c:
void wayland_init_display_devices(void) { - struct ntuser_thread_info *thread_info = NtUserGetThreadInfo(); - DWORD current_pid = GetCurrentProcessId(); - HWND desktop_hwnd = UlongToHandle(thread_info->top_window); - DWORD desktop_pid = 0; - - if (desktop_hwnd) NtUserGetWindowThread(desktop_hwnd, &desktop_pid); - - /* Refresh devices only from the desktop window process. */ - if (!desktop_pid || current_pid == desktop_pid) - wayland_refresh_display_devices(); + wayland_refresh_display_devices(); }
Any reason to keep both `wayland_refresh_display_devices` and `wayland_init_display_devices`? -- https://gitlab.winehq.org/wine/wine/-/merge_requests/2476#note_29754