HWND appwnd;
appwnd = (HWND)w.winId();
QString ClassName("Qt5QWindowIcon");
QString AppName = QStringLiteral("GG");
LPCWSTR app = reinterpret_cast<LPCWSTR>(ClassName.data());
LPCWSTR appCaption = reinterpret_cast<LPCWSTR>(AppName.data());
appwnd = ::FindWindow(app, appCaption);
appwnd = ::FindWindow(app, appCaption);
HWND hwndLogin=FindWindow(NULL,L"登录");
QWidget* widgetLogin=QWidget::find((WId)hwndLogin);
QWindow* windowLogin=QWindow::fromWinId((WId)hwndLogin);
windowLogin->showFullScreen();
::ShowWindow(hWndPrevious,
SW_RESTORE);
// 将主窗激活
::SetForegroundWindow(hWndPrevious);
// 将主窗的对话框激活
::SetForegroundWindow(
::GetLastActivePopup(hWndPrevious));