Ignore:
Timestamp:
Mar 7, 2002, 8:41:18 PM (23 years ago)
Author:
sandervl
Message:

PF: CloseWindow + minimize fixes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/user32/win32wbasepos.cpp

    r7801 r8042  
    1 /* $Id: win32wbasepos.cpp,v 1.27 2002-02-05 17:59:01 sandervl Exp $ */
     1/* $Id: win32wbasepos.cpp,v 1.28 2002-03-07 19:41:18 sandervl Exp $ */
    22/*
    33 * Win32 Window Base Class for OS/2 (nonclient/position methods)
     
    190190LONG Win32BaseWindow::HandleWindowPosChanging(WINDOWPOS *winpos)
    191191{
    192     POINT maxSize;
     192    POINT maxSize, maxTrack, minTrack;
    193193    if (winpos->flags & SWP_NOSIZE) return 0;
    194194
     
    196196        ((dwStyle & (WS_POPUP | WS_CHILD)) == 0))
    197197    {
    198         GetMinMaxInfo( &maxSize, NULL, NULL, NULL );
    199         winpos->cx = MIN( winpos->cx, maxSize.x );
    200         winpos->cy = MIN( winpos->cy, maxSize.y );
     198        GetMinMaxInfo( &maxSize, NULL, &minTrack, &maxTrack );
     199        winpos->cx = MIN( winpos->cx, MAX( maxSize.x, maxTrack.x) );
     200        winpos->cy = MIN( winpos->cy, MAX( maxSize.y, maxTrack.y) );
     201        if (!(dwStyle & WS_MINIMIZE))
     202        {
     203            if (winpos->cx < minTrack.x ) winpos->cx = minTrack.x;
     204            if (winpos->cy < minTrack.y ) winpos->cy = minTrack.y;
     205        }
    201206    }
    202207    return 0;
     
    309314
    310315            if(getParent() == NULL) {
    311                 SetRect(lpRect, -32000, -32000, GetSystemMetrics(SM_CXICON), GetSystemMetrics(SM_CYICON));
    312                 OSLibSetWindowStyle(getOS2FrameWindowHandle(), getOS2WindowHandle(), getStyle(), getExStyle());
     316// @@PF : for now disable windows style - it messes with WV minimize - will fix it soon
     317                 SetRect(lpRect, -32000, -32000, GetSystemMetrics(SM_CXICON), GetSystemMetrics(SM_CYICON));
     318//                OSLibSetWindowStyle(getOS2FrameWindowHandle(), getOS2WindowHandle(), getStyle(), getExStyle());
     319                CloseWindow();
    313320            }
    314321            else {
Note: See TracChangeset for help on using the changeset viewer.