win32ss/user/ntuser/winpos.c | 28 ++++++++++------------------ 1 file changed, 10 insertions(+), 18 deletions(-) diff --git a/win32ss/user/ntuser/winpos.c b/win32ss/user/ntuser/winpos.c index d7f5ad6a63..ad67bc5839 100644 --- a/win32ss/user/ntuser/winpos.c +++ b/win32ss/user/ntuser/winpos.c @@ -65,6 +65,7 @@ static void dump_winpos_flags(UINT flags) TRACE("\n"); } #endif +VOID FASTCALL IntSendNCPaint(PWND pWnd, HRGN hRgn); BOOL FASTCALL IntGetClientOrigin(PWND Window OPTIONAL, LPPOINT Point) @@ -2001,25 +2002,16 @@ co_WinPosSetWindowPos( } if ( !(pwnd->style & WS_CHILD) ) - { - HDC hdc; - HRGN DcRgn = NtGdiCreateRectRgn(0, 0, 0, 0); - PREGION DcRgnObj = REGION_LockRgn(DcRgn); - - TRACE("SWP_FRAMECHANGED Draw\n"); - - IntGdiCombineRgn(DcRgnObj, VisBefore, NULL, RGN_COPY); - REGION_UnlockRgn(DcRgnObj); - - hdc = UserGetDCEx( pwnd, - DcRgn, - DCX_WINDOW|DCX_CACHE|DCX_INTERSECTRGN|DCX_CLIPSIBLINGS|DCX_KEEPCLIPRGN); // DCX_WINDOW, see note above.... - - NC_DoNCPaint(pwnd, hdc, -1); // Force full redraw of nonclient area. + { + HRGN DcRgn = NtGdiCreateRectRgn(0,0,0,0); + PREGION DcRgnObj = REGION_LockRgn(DcRgn); + + TRACE("SWP_FRAMECHANGED Draw\n"); - UserReleaseDC(pwnd, hdc, FALSE); - IntValidateParent(pwnd, DcRgnObj); - GreDeleteObject(DcRgn); + IntGdiCombineRgn(DcRgnObj, VisAfter, NULL, RGN_COPY); + REGION_UnlockRgn(DcRgnObj); + IntSendNCPaint(Window,DcRgn); + GreDeleteObject(DcRgn); } }