Commit 4e2d25c7 authored by Stefan Dösinger's avatar Stefan Dösinger Committed by Alexandre Julliard

comctl32: Re-enable the parent before destroying the dialog.

Prevent 1602 AD from minimizing when the multiplayer dialog is closed. When DestroyWindow is called, user32 tries to find a window to activate, finds the main game window disabled and decides to go to the desktop. Wined3d will help this process by minimizing the game out of the way. Signed-off-by: 's avatarStefan Dösinger <stefan@codeweavers.com> Signed-off-by: 's avatarAlexandre Julliard <julliard@winehq.org>
parent f16396ce
......@@ -2706,6 +2706,7 @@ static INT do_loop(const PropSheetInfo *psInfo)
MSG msg;
INT ret = -1;
HWND hwnd = psInfo->hwnd;
HWND parent = psInfo->ppshheader.hwndParent;
while(IsWindow(hwnd) && !psInfo->ended && (ret = GetMessageW(&msg, NULL, 0, 0)))
{
......@@ -2728,6 +2729,9 @@ static INT do_loop(const PropSheetInfo *psInfo)
if(ret != -1)
ret = psInfo->result;
if(parent)
EnableWindow(parent, TRUE);
DestroyWindow(hwnd);
return ret;
}
......@@ -2754,10 +2758,7 @@ static INT_PTR PROPSHEET_PropertySheet(PropSheetInfo* psInfo, BOOL unicode)
}
bRet = PROPSHEET_CreateDialog(psInfo);
if(!psInfo->isModeless)
{
bRet = do_loop(psInfo);
if (parent) EnableWindow(parent, TRUE);
}
return bRet;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment