Apply patch in bug #7919, blit improvements in
multiwindow mode for Xming/CygwinX
This commit is contained in:
parent
67bd672c88
commit
ce4a0a4dda
|
@ -304,7 +304,6 @@ winTopLevelWindowProc (HWND hwnd, UINT message,
|
||||||
winScreenInfo *s_pScreenInfo = NULL;
|
winScreenInfo *s_pScreenInfo = NULL;
|
||||||
HWND hwndScreen = NULL;
|
HWND hwndScreen = NULL;
|
||||||
DrawablePtr pDraw = NULL;
|
DrawablePtr pDraw = NULL;
|
||||||
int iX, iY, iWidth, iHeight, iBorder;
|
|
||||||
winWMMessageRec wmMsg;
|
winWMMessageRec wmMsg;
|
||||||
Bool fWMMsgInitialized = FALSE;
|
Bool fWMMsgInitialized = FALSE;
|
||||||
static Bool s_fTracking = FALSE;
|
static Bool s_fTracking = FALSE;
|
||||||
|
@ -442,20 +441,19 @@ winTopLevelWindowProc (HWND hwnd, UINT message,
|
||||||
|
|
||||||
/* BeginPaint gives us an hdc that clips to the invalidated region */
|
/* BeginPaint gives us an hdc that clips to the invalidated region */
|
||||||
hdcUpdate = BeginPaint (hwnd, &ps);
|
hdcUpdate = BeginPaint (hwnd, &ps);
|
||||||
|
/* Avoid the BitBlt's if the PAINTSTRUCT is bogus */
|
||||||
/* Get the position and dimensions of the window */
|
if (ps.rcPaint.right==0 && ps.rcPaint.bottom==0 && ps.rcPaint.left==0 && ps.rcPaint.top==0)
|
||||||
iBorder = wBorderWidth (pWin);
|
{
|
||||||
iX = pWin->drawable.x;
|
EndPaint (hwndScreen, &ps);
|
||||||
iY = pWin->drawable.y;
|
return 0;
|
||||||
iWidth = pWin->drawable.width;
|
}
|
||||||
iHeight = pWin->drawable.height;
|
|
||||||
|
|
||||||
/* Try to copy from the shadow buffer */
|
/* Try to copy from the shadow buffer */
|
||||||
if (!BitBlt (hdcUpdate,
|
if (!BitBlt (hdcUpdate,
|
||||||
0, 0,
|
ps.rcPaint.left, ps.rcPaint.top,
|
||||||
iWidth, iHeight,
|
ps.rcPaint.right - ps.rcPaint.left, ps.rcPaint.bottom - ps.rcPaint.top,
|
||||||
s_pScreenPriv->hdcShadow,
|
s_pScreenPriv->hdcShadow,
|
||||||
iX, iY,
|
ps.rcPaint.left + pWin->drawable.x, ps.rcPaint.top + pWin->drawable.y,
|
||||||
SRCCOPY))
|
SRCCOPY))
|
||||||
{
|
{
|
||||||
LPVOID lpMsgBuf;
|
LPVOID lpMsgBuf;
|
||||||
|
|
|
@ -540,8 +540,9 @@ winShadowUpdateGDI (ScreenPtr pScreen,
|
||||||
* handle large regions by creating a clipping region and
|
* handle large regions by creating a clipping region and
|
||||||
* doing a single blit constrained to that clipping region.
|
* doing a single blit constrained to that clipping region.
|
||||||
*/
|
*/
|
||||||
if (pScreenInfo->dwClipUpdatesNBoxes == 0
|
if (!pScreenInfo->fMultiWindow &&
|
||||||
|| dwBox < pScreenInfo->dwClipUpdatesNBoxes)
|
(pScreenInfo->dwClipUpdatesNBoxes == 0 ||
|
||||||
|
dwBox < pScreenInfo->dwClipUpdatesNBoxes))
|
||||||
{
|
{
|
||||||
/* Loop through all boxes in the damaged region */
|
/* Loop through all boxes in the damaged region */
|
||||||
while (dwBox--)
|
while (dwBox--)
|
||||||
|
@ -566,7 +567,7 @@ winShadowUpdateGDI (ScreenPtr pScreen,
|
||||||
++pBox;
|
++pBox;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else if (!pScreenInfo->fMultiWindow)
|
||||||
{
|
{
|
||||||
/* Compute a GDI region from the damaged region */
|
/* Compute a GDI region from the damaged region */
|
||||||
hrgnCombined = CreateRectRgn (pBox->x1, pBox->y1, pBox->x2, pBox->y2);
|
hrgnCombined = CreateRectRgn (pBox->x1, pBox->y1, pBox->x2, pBox->y2);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user