Changeset 2010 for trunk/src/user32/dc.cpp
- Timestamp:
- Dec 7, 1999, 7:19:47 PM (26 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/user32/dc.cpp
r2006 r2010 1 /* $Id: dc.cpp,v 1.2 5 1999-12-07 12:26:58sandervl Exp $ */1 /* $Id: dc.cpp,v 1.26 1999-12-07 18:19:47 sandervl Exp $ */ 2 2 3 3 /* … … 358 358 } 359 359 360 VOID removeClientArea(pDCData pHps)361 {362 pHps->isClient = FALSE;363 364 if (pHps->isClientArea)365 {366 pHps->isClientArea = FALSE;367 GreSetupDC(pHps->hps,368 pHps->hrgnVis,369 pHps->ptlOrigin.x,370 pHps->ptlOrigin.y,371 0,372 SETUPDC_ORIGIN | SETUPDC_VISRGN | SETUPDC_RECALCCLIP);373 }374 }375 376 BOOL selectClientArea(Win32BaseWindow *wnd, pDCData pHps, PRECTL prclPaint)377 {378 RECTL rcl;379 HRGN hrgnRect;380 HWND hwnd;381 382 if (!wnd) return (FALSE);383 384 pHps->isClient = TRUE;385 hwnd = pHps->hwnd;386 387 rcl.xLeft = rcl.yBottom = 0;388 rcl.xRight = wnd->getWindowWidth();389 rcl.yTop = wnd->getWindowHeight();390 391 WinMapWindowPoints(hwnd, HWND_DESKTOP, (PPOINTL) &rcl, 2);392 pHps->ptlOrigin = *((PPOINTL) &rcl);393 394 if (pHps->hrgnVis == 0)395 pHps->hrgnVis = GreCreateRectRegion(pHps->hps, &rcl, 1);396 397 hrgnRect = GreCreateRectRegion(pHps->hps, &rcl, 1);398 399 if (!pHps->isClientArea)400 GreCopyClipRegion(pHps->hps, pHps->hrgnVis, 0, COPYCRGN_VISRGN);401 402 GreCombineRegion(pHps->hps, hrgnRect, pHps->hrgnVis, hrgnRect, CRGN_AND);403 GreSetupDC(pHps->hps,404 hrgnRect,405 rcl.xLeft,406 rcl.yBottom,407 prclPaint,408 SETUPDC_ORIGIN | SETUPDC_VISRGN | SETUPDC_RECALCCLIP);409 410 pHps->isClientArea = TRUE;411 GreDestroyRegion(pHps->hps, hrgnRect);412 413 return (TRUE);414 }415 416 360 HDC sendEraseBkgnd (Win32BaseWindow *wnd) 417 361 { … … 512 456 } 513 457 514 // if (wnd->isFrameWindow())515 // {516 // WinSendMsg( hwnd, /* WM_DRAW */ 0x20D, (MPARAM)hps, MPVOID );517 //CB: subclassed window haven't got a frame518 // if (!wnd->isSubclassedOS2Wnd()) selectClientArea(wnd, pHps, &rect);519 // }520 521 458 if (hPS_ownDC == 0) 522 459 setMapMode (wnd, pHps, MM_TEXT_W); … … 567 504 if (pHps && (pHps->hdcType == TYPE_3)) 568 505 { 569 removeClientArea (pHps);570 506 WinEndPaint (pHps->hps); 571 507 } … … 688 624 goto error; 689 625 690 if (flags & DCX_WINDOW_W)691 removeClientArea (pHps);692 else693 selectClientArea (wnd, pHps, 0);694 695 626 setPageXForm (wnd, pHps); 696 627 … … 725 656 HPSToHDC (hWindow, hps, NULL, NULL); 726 657 pHps = (pDCData)GpiQueryDCData (hps); 727 728 if (!(flags & DCX_WINDOW_W)) {729 if (selectClientArea (wnd, pHps, 0))730 setMapMode (wnd, pHps, MM_TEXT_W);731 }732 658 733 659 if ((flags & DCX_EXCLUDERGN_W) || (flags & DCX_INTERSECTRGN_W))
Note:
See TracChangeset
for help on using the changeset viewer.