mirror of
https://github.com/reactos/reactos.git
synced 2024-10-04 16:36:11 +00:00
Hopefully the last in a series of fixes for size of maximized windows
svn path=/trunk/; revision=17890
This commit is contained in:
parent
d7876f7981
commit
30f4eba8d2
|
@ -351,8 +351,8 @@ co_WinPosMinMaximize(PWINDOW_OBJECT Window, UINT ShowFlag, RECT* NewPos)
|
||||||
|
|
||||||
case SW_MAXIMIZE:
|
case SW_MAXIMIZE:
|
||||||
{
|
{
|
||||||
co_WinPosGetMinMaxInfo(Window, NULL, &InternalPos->MaxPos,
|
co_WinPosGetMinMaxInfo(Window, &Size, &InternalPos->MaxPos,
|
||||||
NULL, &Size);
|
NULL, NULL);
|
||||||
DPRINT("Maximize: %d,%d %dx%d\n",
|
DPRINT("Maximize: %d,%d %dx%d\n",
|
||||||
InternalPos->MaxPos.x, InternalPos->MaxPos.y, Size.x, Size.y);
|
InternalPos->MaxPos.x, InternalPos->MaxPos.y, Size.x, Size.y);
|
||||||
if (Window->Style & WS_MINIMIZE)
|
if (Window->Style & WS_MINIMIZE)
|
||||||
|
@ -420,16 +420,14 @@ WinPosFillMinMaxInfoStruct(PWINDOW_OBJECT Window, MINMAXINFO *Info)
|
||||||
IntGetDesktopWorkArea(Desktop, &WorkArea);
|
IntGetDesktopWorkArea(Desktop, &WorkArea);
|
||||||
|
|
||||||
/* Get default values. */
|
/* Get default values. */
|
||||||
Info->ptMaxSize.x = WorkArea.right - WorkArea.left;
|
|
||||||
Info->ptMaxSize.y = WorkArea.bottom - WorkArea.top;
|
|
||||||
Info->ptMinTrackSize.x = UserGetSystemMetrics(SM_CXMINTRACK);
|
Info->ptMinTrackSize.x = UserGetSystemMetrics(SM_CXMINTRACK);
|
||||||
Info->ptMinTrackSize.y = UserGetSystemMetrics(SM_CYMINTRACK);
|
Info->ptMinTrackSize.y = UserGetSystemMetrics(SM_CYMINTRACK);
|
||||||
Info->ptMaxTrackSize.x = Info->ptMaxSize.x;
|
|
||||||
Info->ptMaxTrackSize.y = Info->ptMaxSize.y;
|
|
||||||
|
|
||||||
IntGetWindowBorderMeasures(Window, &XInc, &YInc);
|
IntGetWindowBorderMeasures(Window, &XInc, &YInc);
|
||||||
Info->ptMaxTrackSize.x += 2 * XInc;
|
Info->ptMaxSize.x = WorkArea.right - WorkArea.left + 2 * XInc;
|
||||||
Info->ptMaxTrackSize.y += 2 * YInc;
|
Info->ptMaxSize.y = WorkArea.bottom - WorkArea.top + 2 * YInc;
|
||||||
|
Info->ptMaxTrackSize.x = Info->ptMaxSize.x;
|
||||||
|
Info->ptMaxTrackSize.y = Info->ptMaxSize.y;
|
||||||
|
|
||||||
if (Window->InternalPos != NULL)
|
if (Window->InternalPos != NULL)
|
||||||
{
|
{
|
||||||
|
@ -437,8 +435,8 @@ WinPosFillMinMaxInfoStruct(PWINDOW_OBJECT Window, MINMAXINFO *Info)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Info->ptMaxPosition.x -= WorkArea.left + XInc;
|
Info->ptMaxPosition.x = WorkArea.left - XInc;
|
||||||
Info->ptMaxPosition.y -= WorkArea.top + YInc;
|
Info->ptMaxPosition.y = WorkArea.top - YInc;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue