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: Stefan Dösinger <stefan@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
f16396ceec
commit
4e2d25c7cd
@ -2706,6 +2706,7 @@ static INT do_loop(const PropSheetInfo *psInfo)
|
|||||||
MSG msg;
|
MSG msg;
|
||||||
INT ret = -1;
|
INT ret = -1;
|
||||||
HWND hwnd = psInfo->hwnd;
|
HWND hwnd = psInfo->hwnd;
|
||||||
|
HWND parent = psInfo->ppshheader.hwndParent;
|
||||||
|
|
||||||
while(IsWindow(hwnd) && !psInfo->ended && (ret = GetMessageW(&msg, NULL, 0, 0)))
|
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)
|
if(ret != -1)
|
||||||
ret = psInfo->result;
|
ret = psInfo->result;
|
||||||
|
|
||||||
|
if(parent)
|
||||||
|
EnableWindow(parent, TRUE);
|
||||||
|
|
||||||
DestroyWindow(hwnd);
|
DestroyWindow(hwnd);
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
@ -2754,10 +2758,7 @@ static INT_PTR PROPSHEET_PropertySheet(PropSheetInfo* psInfo, BOOL unicode)
|
|||||||
}
|
}
|
||||||
bRet = PROPSHEET_CreateDialog(psInfo);
|
bRet = PROPSHEET_CreateDialog(psInfo);
|
||||||
if(!psInfo->isModeless)
|
if(!psInfo->isModeless)
|
||||||
{
|
|
||||||
bRet = do_loop(psInfo);
|
bRet = do_loop(psInfo);
|
||||||
if (parent) EnableWindow(parent, TRUE);
|
|
||||||
}
|
|
||||||
return bRet;
|
return bRet;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user