Changeset 2552 for trunk/src


Ignore:
Timestamp:
Jan 28, 2000, 11:26:01 PM (26 years ago)
Author:
sandervl
Message:

Don't call default frame handler for WM_ADJUSTWINDOWPOS

Location:
trunk/src/user32
Files:
7 edited

Legend:

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

    r2529 r2552  
    1 /* $Id: dc.cpp,v 1.37 2000-01-27 17:21:08 cbratschi Exp $ */
     1/* $Id: dc.cpp,v 1.38 2000-01-28 22:25:59 sandervl Exp $ */
    22
    33/*
     
    438438   HPS      hPS_ownDC = NULLHANDLE;
    439439
    440    dprintf (("USER32: BeginPaint(%x)", hWnd));
    441 
    442440   if ( !lpps )
    443441   {
    444       O32_SetLastError (ERROR_INVALID_PARAMETER);
    445       return (HDC)NULLHANDLE;
     442        dprintf (("USER32: BeginPaint %x invalid parameter %x", hWnd, lpps));
     443        O32_SetLastError (ERROR_INVALID_PARAMETER);
     444        return (HDC)NULLHANDLE;
    446445   }
    447446
     
    459458                if (!pHps)
    460459                {
     460                        dprintf (("USER32: BeginPaint %x invalid parameter %x", hWnd, lpps));
    461461                        O32_SetLastError (ERROR_INVALID_PARAMETER);
    462462                        return (HDC)NULLHANDLE;
     
    504504
    505505   O32_SetLastError(0);
     506   dprintf(("USER32: BeginPaint %x -> hdc %x", hWnd, pHps->hps));
    506507   return (HDC)pHps->hps;
    507508}
     
    688689      hWindow = HWND_DESKTOP;
    689690
    690    dprintf (("User32: GetDCEx hwnd %x (%x %x) -> wnd %x", hwnd, hrgn, flags, wnd));
    691 
    692691   //SvL: Hack for memory.exe (doesn't get repainted properly otherwise)
    693692//   isWindowOwnDC = (((hWindow == HWND_DESKTOP) ? FALSE : (wnd->isOwnDC() && wnd->getOwnDC()))
     
    707706
    708707         pHps->hdcType = TYPE_1;
     708         dprintf (("User32: GetDCEx hwnd %x (%x %x) -> wnd %x hdc %x", hwnd, hrgn, flags, wnd, hps));
    709709         return (HDC)hps;
    710710      }
     
    784784   GpiSetDrawControl (hps, DCTL_DISPLAY, drawingAllowed ? DCTL_ON : DCTL_OFF);
    785785
     786   dprintf (("User32: GetDCEx hwnd %x (%x %x) -> hdc %x", hwnd, hrgn, flags, pHps->hps));
    786787   return (HDC)pHps->hps;
    787788
  • trunk/src/user32/pmframe.cpp

    r2533 r2552  
    1 /* $Id: pmframe.cpp,v 1.40 2000-01-27 21:50:01 sandervl Exp $ */
     1/* $Id: pmframe.cpp,v 1.41 2000-01-28 22:25:59 sandervl Exp $ */
    22/*
    33 * Win32 Frame Managment Code for OS/2
     
    279279          return (MRESULT)0xf;
    280280        }
    281         goto RunDefFrameProc;
     281        RestoreOS2TIB();
     282        return (MRESULT)0;
    282283    }
    283284
  • trunk/src/user32/pmwindow.cpp

    r2533 r2552  
    1 /* $Id: pmwindow.cpp,v 1.82 2000-01-27 21:50:01 sandervl Exp $ */
     1/* $Id: pmwindow.cpp,v 1.83 2000-01-28 22:25:59 sandervl Exp $ */
    22/*
    33 * Win32 Window Managment Code for OS/2
     
    403403        if(wndpars->fsStatus & (WPM_CCHTEXT | WPM_TEXT))
    404404        {
     405            if(wndpars->fsStatus & WPM_TEXT)
     406                win32wnd->MsgGetText(wndpars->pszText, wndpars->cchText);
    405407            if(wndpars->fsStatus & WPM_CCHTEXT)
    406408                wndpars->cchText = win32wnd->MsgGetTextLength();
    407             if(wndpars->fsStatus & WPM_TEXT)
    408                 wndpars->pszText = win32wnd->MsgGetText();
    409409
    410410            wndpars->fsStatus = 0;
  • trunk/src/user32/win32wbase.cpp

    r2533 r2552  
    1 /* $Id: win32wbase.cpp,v 1.147 2000-01-27 21:50:01 sandervl Exp $ */
     1/* $Id: win32wbase.cpp,v 1.148 2000-01-28 22:26:00 sandervl Exp $ */
    22/*
    33 * Win32 Window Base Class for OS/2
     
    649649        if( (SendInternalMessageA(WM_CREATE, 0, (LPARAM)cs )) != -1 )
    650650        {
    651             if(!(flags & WIN_NEED_SIZE)) {
     651            if(!(flags & WIN_NEED_SIZE))
     652            {
     653             LPARAM lParam;
     654
    652655                SendInternalMessageA(WM_SIZE, SIZE_RESTORED,
    653656                                MAKELONG(rectClient.right-rectClient.left,
    654657                                         rectClient.bottom-rectClient.top));
    655                 SendInternalMessageA(WM_MOVE,0,MAKELONG(rectClient.left,rectClient.top));
     658
     659                if(getParent()) {//in parent coordinates
     660                    POINT point;
     661
     662                    point.x = rectClient.left;
     663                    point.y = rectClient.top;
     664                    MapWindowPoints(getWindowHandle(), getParent()->getWindowHandle(), &point, 1);
     665
     666                    lParam = MAKELONG(point.x, point.y);
     667                }
     668                else {//in screen coordinates
     669                    lParam = MAKELONG(rectWindow.left+rectClient.left, rectWindow.top+rectClient.top);
     670                }
     671
     672                SendInternalMessageA(WM_MOVE, 0, lParam);
    656673            }
    657674
     
    10521069    point.y = lpWndPos->y;
    10531070    if (getParent()) ClientToScreen(getParent()->getWindowHandle(),&point);
     1071
    10541072    setWindowRect(point.x,point.y,point.x+lpWndPos->cx,point.y+lpWndPos->cy);
    10551073    newWindowRect = rectWindow;
     
    10931111//******************************************************************************
    10941112//******************************************************************************
    1095 char *Win32BaseWindow::MsgGetText()
    1096 {
    1097     SendInternalMessageA(WM_GETTEXT, wndNameLength, (LPARAM)windowNameA);
    1098     return windowNameA;
     1113void Win32BaseWindow::MsgGetText(char *wndtext, ULONG textlength)
     1114{
     1115    SendInternalMessageA(WM_GETTEXT, textlength, (LPARAM)wndtext);
    10991116}
    11001117//******************************************************************************
     
    13951412            SetCursor(hCursor);
    13961413            return 1;
    1397           } else return 0;
    1398         } else return 0;
     1414          }
     1415          else return 0;
     1416        }
     1417        else return 0;
    13991418    }
    14001419
     
    14091428        if (!(wpos->flags & SWP_NOMOVE) && !(wpos->flags & SWP_NOCLIENTMOVE))
    14101429        {
    1411             SendInternalMessageA(WM_MOVE,0,MAKELONG(rectClient.left,rectClient.top));
     1430            SendInternalMessageA(WM_MOVE, 0, MAKELONG(wpos->x + rectClient.left, wpos->y + rectClient.top));
    14121431        }
    14131432        if (!(wpos->flags & SWP_NOSIZE) && !(wpos->flags & SWP_NOCLIENTSIZE))
    14141433        {
    14151434            if (dwStyle & WS_MAXIMIZE) wp = SIZE_MAXIMIZED;
    1416             else if (dwStyle & WS_MINIMIZE) wp = SIZE_MINIMIZED;
     1435            else
     1436            if (dwStyle & WS_MINIMIZE) wp = SIZE_MINIMIZED;
    14171437
    14181438            SendInternalMessageA(WM_SIZE, wp, MAKELONG(rectClient.right  - rectClient.left,
  • trunk/src/user32/win32wbase.h

    r2533 r2552  
    1 /* $Id: win32wbase.h,v 1.76 2000-01-27 21:50:02 sandervl Exp $ */
     1/* $Id: win32wbase.h,v 1.77 2000-01-28 22:26:00 sandervl Exp $ */
    22/*
    33 * Win32 Window Base Class for OS/2
     
    123123         ULONG  MsgSetText(LPSTR lpsz, LONG cch);
    124124         ULONG  MsgGetTextLength();
    125          char  *MsgGetText();
     125         void   MsgGetText(char *wndtext, ULONG textlength);
    126126         VOID   updateWindowStyle(DWORD oldExStyle,DWORD oldStyle);
    127127
  • trunk/src/user32/window.cpp

    r2529 r2552  
    1 /* $Id: window.cpp,v 1.52 2000-01-27 17:21:10 cbratschi Exp $ */
     1/* $Id: window.cpp,v 1.53 2000-01-28 22:26:01 sandervl Exp $ */
    22/*
    33 * Win32 window apis for OS/2
     
    653653    else
    654654      window = windowDesktop;
     655
    655656    if(!window) {
    656657        dprintf(("GetWindowRect, window %x not found", hwnd));
     
    662663        return FALSE;
    663664    }
    664     *pRect = *window->getWindowRect();
     665    *pRect = *window->getWindowRect(); //always in screen coordinates
     666
    665667    dprintf(("GetWindowRect %x (%d,%d) (%d,%d)", hwnd, pRect->left, pRect->top, pRect->right, pRect->bottom));
    666668    return TRUE;
     
    928930{
    929931    HWND DesktopWindow = windowDesktop->getWindowHandle();
    930     dprintf(("USER32: GetDesktopWindow, return %d\n", DesktopWindow));
     932    dprintf2(("USER32: GetDesktopWindow, returned %d\n", DesktopWindow));
    931933    return DesktopWindow;
    932934}
     
    10531055    DWP *pDWP;
    10541056
    1055     dprintf(("USER32:  BeginDeferWindowPos\n"));
    10561057    if (count <= 0)
    10571058    {
     1059        dprintf(("USER32: BeginDeferWindowPos invalid param %d", count));
    10581060        SetLastError(ERROR_INVALID_PARAMETER);
    10591061        return 0;
    10601062    }
     1063    dprintf(("USER32: BeginDeferWindowPos %d", count));
    10611064    handle = (HDWP)HeapAlloc(GetProcessHeap(), 0, sizeof(DWP) + (count-1)*sizeof(WINDOWPOS) );
    10621065    if (!handle)
     
    11001103    }
    11011104
     1105    dprintf(("USER32: DeferWindowPos hdwp %x hwnd %x hwndAfter %x (%d,%d)(%d,%d) %x", hdwp, hwnd, hwndAfter,
     1106              x, y, cx, cy, flags));
    11021107
    11031108/* Numega Bounds Checker Demo dislikes the following code.
  • trunk/src/user32/wndmsg.cpp

    r2533 r2552  
    1 /* $Id: wndmsg.cpp,v 1.11 2000-01-27 21:50:03 sandervl Exp $ */
     1/* $Id: wndmsg.cpp,v 1.12 2000-01-28 22:26:01 sandervl Exp $ */
    22/*
    33 * Win32 window message text function for OS/2
     
    712712        if(PostSpyMessage(hwnd, Msg, wParam, lParam) == FALSE)
    713713        {
    714 #if 1
    715             if(!CheckCurFS()) {
    716                 dprintf(("FS CORRUPT!!!!"));
    717             }
    718 #endif
    719714            if(fInternalMsg) {
    720715                    dprintf(("SendInternalMessage%c %s for %x %x %x", unicode, GetMsgText(Msg), hwnd, wParam, lParam));
Note: See TracChangeset for help on using the changeset viewer.