Ignore:
Timestamp:
Jul 19, 1999, 8:40:44 PM (26 years ago)
Author:
sandervl
Message:

Point/Rectangle bug fixes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/user32/new/win32wnd.cpp

    r338 r340  
    1 /* $Id: win32wnd.cpp,v 1.15 1999-07-19 13:58:38 sandervl Exp $ */
     1/* $Id: win32wnd.cpp,v 1.16 1999-07-19 18:40:44 sandervl Exp $ */
    22/*
    33 * Win32 Window Code for OS/2
     
    391391        OffsetRect(&rectWindow, maxPos.x - rectWindow.left,
    392392                                          maxPos.y - rectWindow.top);
    393     dprintf(("Sending WM_CREATE"));
     393        dprintf(("Sending WM_CREATE"));
    394394        if( (SendInternalMessage(WM_CREATE, 0, (LPARAM)cs )) != -1 )
    395395        {
    396396            SetWindowPos(HWND_TOP, rectClient.left, rectClient.top,
    397              rectClient.right-rectClient.left,
    398              rectClient.bottom-rectClient.top,
    399              SWP_NOACTIVATE);
     397                         rectClient.right-rectClient.left,
     398                         rectClient.bottom-rectClient.top,
     399                         SWP_NOACTIVATE);
    400400
    401401            if (cs->style & WS_VISIBLE) ShowWindow( sw );
     
    12411241 RECT rect;
    12421242
    1243   if(OSLibWinQueryUpdateRect(OS2Hwnd, &rect))
    1244   {//update region not empty
    1245     SendInternalMessageA((isIcon) ? WM_PAINTICON : WM_PAINT, 0, 0);
    1246   }
    1247   return TRUE;
     1243    if(OSLibWinQueryUpdateRect(OS2Hwnd, &rect))
     1244    {//update region not empty
     1245        SendInternalMessageA((isIcon) ? WM_PAINTICON : WM_PAINT, 0, 0);
     1246    }
     1247    return TRUE;
    12481248}
    12491249//******************************************************************************
     
    12511251BOOL Win32Window::IsIconic()
    12521252{
    1253   return OSLibWinIsIconic(OS2Hwnd);
     1253    return OSLibWinIsIconic(OS2Hwnd);
    12541254}
    12551255//******************************************************************************
     
    12631263 HWND          hwndRelated;
    12641264
    1265   dprintf(("GetWindow %x %d NOT COMPLETE", getWindowHandle(), uCmd));
    1266   switch(uCmd)
    1267   {
    1268     case GW_CHILD:
    1269         getcmd = QWOS_TOP;
    1270         break;
    1271     case GW_HWNDFIRST:
    1272         if(getParent()) {
    1273             getcmd = QWOS_TOP; //top of child windows
    1274         }
    1275         else    getcmd = QWOS_TOP; //TODO
    1276         break;
    1277     case GW_HWNDLAST:
    1278         if(getParent()) {
    1279             getcmd = QWOS_BOTTOM; //bottom of child windows
    1280         }
    1281         else    getcmd = QWOS_BOTTOM; //TODO
    1282         break;
    1283     case GW_HWNDNEXT:
    1284         getcmd = QWOS_NEXT;
    1285         break;
    1286     case GW_HWNDPREV:
    1287         getcmd = QWOS_PREV;
    1288         break;
    1289     case GW_OWNER:
    1290         if(owner) {
    1291             return owner->getWindowHandle();
    1292         }
    1293         else    return 0;
    1294   }
    1295   hwndRelated = OSLibWinQueryWindow(OS2Hwnd, getcmd);
    1296   if(hwndRelated)
    1297   {
    1298     win32wnd = (Win32Window *)OSLibWinGetWindowULong(hwndRelated, OFFSET_WIN32WNDPTR);
    1299     magic    = OSLibWinGetWindowULong(hwndRelated, OFFSET_WIN32PM_MAGIC);
    1300     if(CheckMagicDword(magic) && win32wnd)
     1265    dprintf(("GetWindow %x %d NOT COMPLETE", getWindowHandle(), uCmd));
     1266    switch(uCmd)
    13011267    {
    1302         return win32wnd->getWindowHandle();
     1268        case GW_CHILD:
     1269            getcmd = QWOS_TOP;
     1270            break;
     1271        case GW_HWNDFIRST:
     1272            if(getParent()) {
     1273                    getcmd = QWOS_TOP; //top of child windows
     1274            }
     1275            else    getcmd = QWOS_TOP; //TODO
     1276            break;
     1277        case GW_HWNDLAST:
     1278            if(getParent()) {
     1279                    getcmd = QWOS_BOTTOM; //bottom of child windows
     1280            }
     1281            else    getcmd = QWOS_BOTTOM; //TODO
     1282            break;
     1283        case GW_HWNDNEXT:
     1284            getcmd = QWOS_NEXT;
     1285            break;
     1286        case GW_HWNDPREV:
     1287            getcmd = QWOS_PREV;
     1288            break;
     1289        case GW_OWNER:
     1290            if(owner) {
     1291                    return owner->getWindowHandle();
     1292            }
     1293            else    return 0;
    13031294    }
    1304   }
    1305   return 0;
     1295    hwndRelated = OSLibWinQueryWindow(OS2Hwnd, getcmd);
     1296    if(hwndRelated)
     1297    {
     1298        win32wnd = (Win32Window *)OSLibWinGetWindowULong(hwndRelated, OFFSET_WIN32WNDPTR);
     1299        magic    = OSLibWinGetWindowULong(hwndRelated, OFFSET_WIN32PM_MAGIC);
     1300        if(CheckMagicDword(magic) && win32wnd)
     1301        {
     1302            return win32wnd->getWindowHandle();
     1303        }
     1304    }
     1305    return 0;
    13061306}
    13071307//******************************************************************************
Note: See TracChangeset for help on using the changeset viewer.