Changeset 2335 for trunk/src/user32/new/pmframe.cpp
- Timestamp:
- Jan 5, 2000, 10:25:08 PM (26 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/user32/new/pmframe.cpp
r2309 r2335 1 /* $Id: pmframe.cpp,v 1. 4 2000-01-03 20:53:50cbratschi Exp $ */1 /* $Id: pmframe.cpp,v 1.5 2000-01-05 21:25:05 cbratschi Exp $ */ 2 2 /* 3 3 * Win32 Frame Managment Code for OS/2 … … 262 262 PSWP pswp = (PSWP)mp1,swpClient; 263 263 RECTL *client = (PRECTL)mp2,rect; 264 RECT winRect; 264 265 INT ccount; 265 266 … … 269 270 ccount = (INT)OldFrameProc(hwnd,msg,mp1,mp2); 270 271 SetWin32TIB(); 272 dprintf(("Frame size: %d %d",win32wnd->getWindowWidth(),win32wnd->getWindowHeight())); 273 win32wnd->MsgFormatFrame(); 274 //CB: todo: use result for WM_CALCVALIDRECTS 271 275 mapWin32ToOS2Rect(WinQueryWindow(hwnd,QW_PARENT),win32wnd->getClientRectPtr(),(PRECTLOS2)&rect); 272 276 WinMapWindowPoints(WinQueryWindow(hwnd,QW_PARENT),hwnd,(PPOINTL)&rect,2); 273 //dprintf(("CB: %d %d %d %d",rect.xLeft,rect.yBottom,rect.xRight,rect.yTop));277 dprintf(("New client position: %d %d %d %d",rect.xLeft,rect.yBottom,rect.xRight,rect.yTop)); 274 278 swpClient = &pswp[ccount-1]; 275 279 swpClient->x = rect.xLeft; … … 339 343 else 340 344 { 341 dprintf((" USER32: WM_HITTEST %x (%d,%d)",hwnd,(*(POINTS *)&mp1).x,(*(POINTS *)&mp1).y));345 dprintf(("PMFRAME: WM_HITTEST %x (%d,%d)",hwnd,(*(POINTS *)&mp1).x,(*(POINTS *)&mp1).y)); 342 346 343 347 //CB: WinWindowFromPoint: PM sends WM_HITTEST -> loop -> stack overflow … … 351 355 352 356 case WM_PAINT: 357 //CB: todo: call defframe if minimized 353 358 dprintf(("PMFRAME: WM_PAINT")); 354 359 if (win32wnd->IsWindowCreated()) … … 356 361 goto RunDefWndProc; 357 362 358 //CB: not yet checked 363 case WM_SIZE: 364 dprintf(("PMFRAME: WM_SIZE")); 365 goto RunDefFrameProc; 366 359 367 case WM_ADJUSTWINDOWPOS: 360 368 { … … 381 389 goto RunDefFrameProc; 382 390 383 if(!win32wnd->CanReceiveSizeMsgs()) { 384 //SvL: Doing this breaks button.exe, header4(a).exe & style.exe 385 // goto RunDefFrameProc; //CB: must call def frame proc or frame control activation is broken 386 break; 387 } 391 if(!win32wnd->CanReceiveSizeMsgs()) 392 break; 388 393 389 394 WinQueryWindowPos(hwnd, &swpOld); … … 419 424 pswp->hwnd = hwnd; 420 425 421 // goto RunDefFrameProc; //CB: must call def frame proc or frame control activation is broken422 426 RestoreOS2TIB(); 423 427 return (MRESULT)0xf; 424 428 } 425 goto RunDefFrameProc; //CB: must call def frame proc or frame control activation is broken429 goto RunDefFrameProc; 426 430 } 427 431 … … 434 438 435 439 dprintf(("PMFRAME: WM_WINDOWPOSCHANGED (%x) %x %x (%d,%d) (%d,%d)", mp2, win32wnd->getWindowHandle(), pswp->fl, pswp->x, pswp->y, pswp->cx, pswp->cy)); 436 437 RestoreOS2TIB();438 rc = OldFrameProc(hwnd,msg,mp1,mp2);439 SetWin32TIB();440 440 441 441 if ((pswp->fl & (SWP_SIZE | SWP_MOVE | SWP_ZORDER)) == 0) … … 453 453 454 454 win32wnd->setWindowRect(wp.x, wp.y, wp.x+wp.cx, wp.y+wp.cy); 455 win32wnd->setClientRect(swpOld.x, swpOld.y, swpOld.x + swpOld.cx, swpOld.y + swpOld.cy); 456 455 dprintf(("CB: %d %d %d %d",wp.x,wp.y,wp.x+wp.cx,wp.y+wp.cy)); 457 456 if(win32wnd->CanReceiveSizeMsgs()) 458 457 win32wnd->MsgPosChanged((LPARAM)&wp); 459 458 460 459 PosChangedEnd: 460 //calls WM_FORMATFRAME if SWP_SIZE is set 461 RestoreOS2TIB(); 462 rc = OldFrameProc(hwnd,msg,mp1,mp2); 463 SetWin32TIB(); 464 461 465 RestoreOS2TIB(); 462 466 return rc;
Note:
See TracChangeset
for help on using the changeset viewer.