// 这段代码将当前窗口带到带到最顶层,并设置为活动窗口
HWND hForegdWnd = ::GetForegroundWindow();
DWORD dwCurID = ::GetCurrentThreadId();
DWORD dwForeID = ::GetWindowThreadProcessId(hForegdWnd, NULL);
::AttachThreadInput(dwCurID, dwForeID, TRUE);
::SetForegroundWindow(GetSafeHwnd());
::AttachThreadInput(dwCurID, dwForeID, FALSE);
如何将当前窗口带到带到最顶层,并设置为活动窗口
最新推荐文章于 2024-08-27 22:46:58 发布