From 2b62e9b22c42c11cf3587db01dd72a70112148aa Mon Sep 17 00:00:00 2001 From: Richard Campbell Date: Fri, 28 Mar 2003 18:59:18 +0000 Subject: [PATCH] Fixes a client area issue in winemine and other apps. svn path=/trunk/; revision=4449 --- reactos/subsys/win32k/ntuser/window.c | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/reactos/subsys/win32k/ntuser/window.c b/reactos/subsys/win32k/ntuser/window.c index c5d8a18f3d2..6bae515959a 100644 --- a/reactos/subsys/win32k/ntuser/window.c +++ b/reactos/subsys/win32k/ntuser/window.c @@ -1,4 +1,4 @@ -/* $Id: window.c,v 1.39 2003/03/24 23:08:51 rcampbell Exp $ +/* $Id: window.c,v 1.40 2003/03/28 18:59:18 rcampbell Exp $ * * COPYRIGHT: See COPYING in the top level directory * PROJECT: ReactOS kernel @@ -869,13 +869,21 @@ NtUserMoveWindow( Window->WindowRect.bottom = Window->ClientRect.bottom = pWinPos.cy; Window->WindowRect.right = Window->ClientRect.right = pWinPos.cx; - if (uStyle & WS_BORDER) + if (!(uStyle & WS_THICKFRAME)) { - Window->ClientRect.top += NtUserGetSystemMetrics(SM_CYSIZEFRAME); - Window->ClientRect.bottom -= NtUserGetSystemMetrics(SM_CYSIZEFRAME); - Window->ClientRect.left += NtUserGetSystemMetrics(SM_CXSIZEFRAME); - Window->ClientRect.right -= NtUserGetSystemMetrics(SM_CXSIZEFRAME); + Window->ClientRect.top += NtUserGetSystemMetrics(SM_CYFIXEDFRAME); + Window->ClientRect.bottom -= NtUserGetSystemMetrics(SM_CYFIXEDFRAME); + Window->ClientRect.left += NtUserGetSystemMetrics(SM_CXFIXEDFRAME); + Window->ClientRect.right -= NtUserGetSystemMetrics(SM_CXFIXEDFRAME); } + else + { + Window->ClientRect.top += NtUserGetSystemMetrics(SM_CYSIZEFRAME); + Window->ClientRect.bottom -= NtUserGetSystemMetrics(SM_CYSIZEFRAME); + Window->ClientRect.left += NtUserGetSystemMetrics(SM_CXSIZEFRAME); + Window->ClientRect.right -= NtUserGetSystemMetrics(SM_CXSIZEFRAME); + } + if (uStyle & WS_CAPTION) Window->ClientRect.top += NtUserGetSystemMetrics(SM_CYCAPTION); if ( Window->Class->Class.lpszMenuName) @@ -1159,7 +1167,7 @@ BOOL STDCALL NtUserUpdateWindow( HWND hWnd ) return FALSE; if (pWindow->UpdateRegion) NtUserSendMessage( hWnd, WM_PAINT,0,0); - + W32kReleaseWindowObject(pWindow); return TRUE; }