Source/win32/WIN32Server.m (-setmaxsize::): Remove the maximize box when a maximum size is set on a window.

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/back/trunk@31197 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
ericwa 2010-08-24 23:20:01 +00:00
parent aaf1d7ab06
commit b8d4c6674a
2 changed files with 17 additions and 0 deletions

View file

@ -1,3 +1,8 @@
2010-08-24 Eric Wasylishen <ewasylishen@gmail.com>
* Source/win32/WIN32Server.m (-setmaxsize::):
Remove the maximize box when a maximum size is set on a window.
2010-08-10 Fred Kiefer <FredKiefer@gmx.de>
* Source/cairo/CairoFontEnumerator.m,

View file

@ -1384,6 +1384,18 @@ LRESULT CALLBACK MainWndProc(HWND hwnd, UINT uMsg,
p.x = size.width;
p.y = size.height;
win->minmax.ptMaxTrackSize = p;
// Disable the maximize box if a maximum size is set
if (size.width < 10000 || size.height < 10000)
{
SetWindowLong((HWND)winNum, GWL_STYLE,
GetWindowLong((HWND)winNum, GWL_STYLE) ^ WS_MAXIMIZEBOX);
}
else
{
SetWindowLong((HWND)winNum, GWL_STYLE,
GetWindowLong((HWND)winNum, GWL_STYLE) | WS_MAXIMIZEBOX);
}
}
/** Set the minimum size of the window */