Commit Graph

1 Commits

Author SHA1 Message Date
ec41c2201c shims: find_title_window, the title's own window that PresentX shows its frames in
A GDKX title makes its own top-level Win32 window before its first PresentX, and PresentX names no window: on the PC
the frames belong in that window. Measured on a retail executable: by the first PresentX the process has one visible,
unowned top-level window on a thread of its own, and only hidden windows besides (IME, a driver's dummy window). The
PresentX wiring (#2490) built a hidden window of its own instead, so a running title showed a blank window.

find_title_window picks the visible, unowned, non-tool top-level window of the process with the largest client area.
It sends no message: a lookup that read window titles with GetWindowTextW (a WM_GETTEXT sent across threads) stopped
the retail title at its first PresentX, because the title's window thread was not pumping at that moment.

title_window_test makes the windows on a thread that never pumps; the negative control shows a sent WM_GETTEXT times out
there, while the lookup answers at once and skips the larger hidden, owned and tool windows.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-23 20:02:18 +01:00