diff options
Diffstat (limited to 'xorg-server/hw/xwin/winshadddnl.c')
-rw-r--r-- | xorg-server/hw/xwin/winshadddnl.c | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/xorg-server/hw/xwin/winshadddnl.c b/xorg-server/hw/xwin/winshadddnl.c index e7306151e..7668bd1c0 100644 --- a/xorg-server/hw/xwin/winshadddnl.c +++ b/xorg-server/hw/xwin/winshadddnl.c @@ -523,7 +523,7 @@ winShadowUpdateDDNL(ScreenPtr pScreen, shadowBufPtr pBuf) POINT ptOrigin; DWORD dwBox = RegionNumRects(damage); BoxPtr pBox = RegionRects(damage); - HRGN hrgnTemp = NULL, hrgnCombined = NULL; + HRGN hrgnCombined = NULL; /* * Return immediately if the app is not active @@ -595,15 +595,9 @@ winShadowUpdateDDNL(ScreenPtr pScreen, shadowBufPtr pBuf) BoxPtr pBoxExtents = RegionExtents(damage); /* Compute a GDI region from the damaged region */ - hrgnCombined = CreateRectRgn(pBox->x1, pBox->y1, pBox->x2, pBox->y2); - dwBox--; - pBox++; - while (dwBox--) { - hrgnTemp = CreateRectRgn(pBox->x1, pBox->y1, pBox->x2, pBox->y2); - CombineRgn(hrgnCombined, hrgnCombined, hrgnTemp, RGN_OR); - DeleteObject(hrgnTemp); - pBox++; - } + hrgnCombined = + CreateRectRgn(pBoxExtents->x1, pBoxExtents->y1, pBoxExtents->x2, + pBoxExtents->y2); /* Install the GDI region as a clipping region */ SelectClipRgn(pScreenPriv->hdcScreen, hrgnCombined); |