Add window-based target picker as the default; process list goes advanced
New host/src/inject/window_list.{hpp,cpp} enumerates visible, titled, non-tool
top-level (alt-tab-style) windows via EnumWindows -- root-owner only, our own
process excluded -- and maps each to its owning pid + image name. The Injection
panel now defaults to this window list (each row "title [process.exe pid]", with a
filter over title or process), since there are far fewer windows than processes and
a window maps straight to the HWND the capturer wants. The full process list stays
as the advanced picker under Debug details.
Verified live: launched the host and captured its window -- the picker lists real
windows (Discord/Firefox/Explorer/...) in "title [exe pid]" form, filter present,
and the host's own window correctly excluded. x64 build green.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
10
README.md
10
README.md
@@ -75,16 +75,6 @@ is removed from this list once done — so the top item is always next. The
|
||||
self-verifiable tooling / UI / input items come first; the game-pipeline items that
|
||||
need a real game (and Remote Play) to fully validate come last.
|
||||
|
||||
- **Select targets by window, not just process.** A flat process list is fine as an
|
||||
advanced/debug view, but the default should be a **window list** — there are far
|
||||
fewer top-level windows than processes, and a window directly yields the HWND the
|
||||
WGC capturer and focus spoof already want. *How:* add a window enumerator
|
||||
(`EnumWindows`, keeping visible, titled, non-tool top-level windows —
|
||||
`IsWindowVisible`, `GetWindowTextLength > 0`, exclude `WS_EX_TOOLWINDOW` and our own
|
||||
HWND, resolve to the root owner) and map each via `GetWindowThreadProcessId` → pid →
|
||||
image name. Show **title + process name + pid** with a filter box like the process
|
||||
list; injecting by window injects into its pid and hands the HWND straight to
|
||||
capture. Keep the process list behind "Debug details" as the advanced path.
|
||||
- **Auto-size and lay out the overlay windows so none need manual resizing.** Panels
|
||||
currently `Begin` at default cascade positions, so they overlap and clip. Give each
|
||||
`ImGuiWindowFlags_AlwaysAutoResize` and an initial position computed from
|
||||
|
||||
Reference in New Issue
Block a user