Changeset 1516 for trunk/src


Ignore:
Timestamp:
Oct 30, 1999, 12:55:16 PM (26 years ago)
Author:
sandervl
Message:

MapDialogRect fix

Location:
trunk/src/user32
Files:
5 edited

Legend:

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

    r1495 r1516  
    1 /* $Id: user32.cpp,v 1.48 1999-10-28 18:22:28 sandervl Exp $ */
     1/* $Id: user32.cpp,v 1.49 1999-10-30 10:55:15 sandervl Exp $ */
    22
    33/*
     
    22442244}
    22452245
    2246 /* Dialog Box Functions */
    2247 
    2248 BOOL WIN32API MapDialogRect( HWND hDlg, PRECT  lpRect)
    2249 {
    2250 #ifdef DEBUG
    2251     WriteLog("USER32:  MapDialogRect\n");
    2252 #endif
    2253     hDlg = Win32Window::Win32ToOS2Handle(hDlg);
    2254 
    2255     return O32_MapDialogRect(hDlg,lpRect);
    2256 }
    2257 
    22582246/* Icon Functions */
    22592247int WIN32API LookupIconIdFromDirectory(PBYTE presbits, BOOL fIcon)
  • trunk/src/user32/win32dlg.cpp

    r1513 r1516  
    1 /* $Id: win32dlg.cpp,v 1.22 1999-10-30 09:19:45 sandervl Exp $ */
     1/* $Id: win32dlg.cpp,v 1.23 1999-10-30 10:55:15 sandervl Exp $ */
    22/*
    33 * Win32 Dialog Code for OS/2
     
    236236    dprintf(("********* DIALOG CREATION FAILED! ************"));
    237237    return FALSE;
     238}
     239//******************************************************************************
     240//******************************************************************************
     241BOOL Win32Dialog::MapDialogRect(LPRECT rect)
     242{
     243    rect->left   = (rect->left * xUnit) / 4;
     244    rect->right  = (rect->right * xUnit) / 4;
     245    rect->top    = (rect->top * yUnit) / 8;
     246    rect->bottom = (rect->bottom * yUnit) / 8;
     247    return TRUE;
    238248}
    239249/***********************************************************************
  • trunk/src/user32/win32dlg.h

    r1346 r1516  
    1 /* $Id: win32dlg.h,v 1.4 1999-10-17 20:18:45 sandervl Exp $ */
     1/* $Id: win32dlg.h,v 1.5 1999-10-30 10:55:16 sandervl Exp $ */
    22/*
    33 * Win32 Dialog Code for OS/2
     
    7373         BOOL   endDialog(int retval);
    7474
     75         BOOL   MapDialogRect(LPRECT rect);
     76
    7577virtual  ULONG  MsgCreate(HWND hwndFrame, HWND hwndClient);
    7678
  • trunk/src/user32/windlg.cpp

    r1346 r1516  
    1 /* $Id: windlg.cpp,v 1.7 1999-10-17 20:18:46 sandervl Exp $ */
     1/* $Id: windlg.cpp,v 1.8 1999-10-30 10:55:16 sandervl Exp $ */
    22/*
    33 * Win32 dialog apis for OS/2
     
    197197    return -1;
    198198}
     199/***********************************************************************
     200 *           MapDialogRect32   (USER32.382)
     201 */
     202BOOL WIN32API MapDialogRect(HWND hwndDlg, LPRECT rect)
     203{
     204  Win32Dialog *dialog;
     205
     206    dialog = (Win32Dialog *)Win32BaseWindow::GetWindowFromHandle(hwndDlg);
     207    if(!dialog || !dialog->IsDialog()) {
     208        dprintf(("MapDialogRect, window %x not found", hwndDlg));
     209        SetLastError(ERROR_INVALID_WINDOW_HANDLE);
     210        return 0;
     211    }
     212    dprintf(("USER32: MapDialogRect\n"));
     213    return dialog->MapDialogRect(rect);
     214}
    199215//******************************************************************************
    200216//******************************************************************************
  • trunk/src/user32/window.cpp

    r1513 r1516  
    1 /* $Id: window.cpp,v 1.27 1999-10-30 09:19:47 sandervl Exp $ */
     1/* $Id: window.cpp,v 1.28 1999-10-30 10:55:16 sandervl Exp $ */
    22/*
    33 * Win32 window apis for OS/2
     
    181181        }
    182182    }
     183    if(HIWORD(className)) {
     184         dprintf(("CreateWindowExW: class %s parent %x (%d,%d) (%d,%d), %x %x", className, parent, x, y, width, height, style, exStyle));
     185    }
     186    else dprintf(("CreateWindowExW: class %d parent %x (%d,%d) (%d,%d), %x %x", className, parent, x, y, width, height, style, exStyle));
    183187
    184188    /* Create the window */
Note: See TracChangeset for help on using the changeset viewer.