[idd] ensure the only active monitor is the IDD

This commit is contained in:
Geoffrey McRae committed 2026-07-23 09:44:00 +10:00
1 parent 58e0cf340d
commit 6f2a81edf8
5 files changed
+256 -7

No files matched your search

+5 -1
View File
@@ -124,6 +124,10 @@ int WINAPI WinMain(_In_ HINSTANCE hInstance, _In_opt_ HINSTANCE hPrevInstance, _
g_pipe.ReloadSettings();
});
window.onDisplayChange([]() {
return g_pipe.EnsureOnlyDisplay();
});
HANDLE hWait;
if (!RegisterWaitForSingleObject(&hWait, hParent.Get(), DestroyNotifyWindow, &window, INFINITE, WT_EXECUTEONLYONCE))
DEBUG_ERROR_HR(GetLastError(), "Failed to RegisterWaitForSingleObject");
@@ -445,4 +449,4 @@ static void Launch()
l_process.Attach(pi.hProcess);
CloseHandle(pi.hThread);
}
}