Changeset 2437 for trunk/src/user32/new/pmwindow.cpp
- Timestamp:
- Jan 14, 2000, 3:45:18 PM (26 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/user32/new/pmwindow.cpp
r2435 r2437 1 /* $Id: pmwindow.cpp,v 1.4 1 2000-01-14 13:16:57sandervl Exp $ */1 /* $Id: pmwindow.cpp,v 1.42 2000-01-14 14:45:16 sandervl Exp $ */ 2 2 /* 3 3 * Win32 Window Managment Code for OS/2 … … 459 459 //****************************************************************************** 460 460 //****************************************************************************** 461 MRESULT EXPENTRY Win32SubclassWindowProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2)462 {463 Win32BaseWindow* win32wnd;464 465 //Restore our FS selector466 SetWin32TIB();467 468 win32wnd = Win32BaseWindow::GetWindowFromOS2Handle(hwnd);469 470 if (!win32wnd)471 {472 dprintf(("Invalid win32wnd pointer for subclassed window %x!!", hwnd));473 goto RunDefWndProc;474 }475 476 switch (msg)477 {478 case WM_WINDOWPOSCHANGED:479 {480 PSWP pswp = (PSWP)mp1;481 SWP swpOld = *(pswp + 1);482 WINDOWPOS wp;483 HWND hParent = NULLHANDLE, hFrame = NULLHANDLE;484 485 dprintf(("OS2Subclass: WM_WINDOWPOSCHANGED %x %x (%d,%d) (%d,%d)", hwnd, pswp->fl, pswp->x, pswp->y, pswp->cx, pswp->cy));486 if ((pswp->fl & (SWP_SIZE | SWP_MOVE | SWP_ZORDER)) == 0) break;487 488 hParent = hFrame = WinQueryWindow(hwnd, QW_PARENT);489 490 OSLibMapSWPtoWINDOWPOS(pswp,&wp, &swpOld,hParent,hFrame);491 492 win32wnd->setWindowRect(swpOld.x, swpOld.y, swpOld.x + swpOld.cx, swpOld.y + swpOld.cy);493 //win32wnd->setClientRect(swpOld.x, swpOld.y, swpOld.x + swpOld.cx, swpOld.y + swpOld.cy);494 wp.x = swpOld.x;495 wp.y = swpOld.y;496 wp.cx = swpOld.cx;497 wp.cy = swpOld.cy;498 499 wp.hwnd = win32wnd->getWindowHandle();500 501 win32wnd->MsgPosChanged((LPARAM)&wp);502 503 goto RunOldWndProc;504 }505 506 default:507 goto RunDefHandler;508 }509 510 RunDefWndProc:511 RestoreOS2TIB();512 return WinDefWindowProc(hwnd,msg,mp1,mp2);513 514 RunOldWndProc:515 RestoreOS2TIB();516 return ((PFNWP)win32wnd->getOldWndProc())(hwnd,msg,mp1,mp2);517 518 RunDefHandler:519 RestoreOS2TIB();520 return Win32WindowProc(hwnd,msg,mp1,mp2);521 }522 523 PVOID SubclassWithDefHandler(HWND hwnd)524 {525 return WinSubclassWindow(hwnd,Win32SubclassWindowProc);526 }
Note:
See TracChangeset
for help on using the changeset viewer.