Commit 6b1e75d2 authored by Alexandre Julliard's avatar Alexandre Julliard

x11drv: Clipping fix with DIB section copy.

Use the GC of the destination device in X11DRV_DIB_CopyDIBSection so that the clipping region is taken into account.
parent 510c94d2
...@@ -4152,7 +4152,7 @@ static void X11DRV_DIB_DoProtectDIBSection( X_PHYSBITMAP *physBitmap, DWORD new_ ...@@ -4152,7 +4152,7 @@ static void X11DRV_DIB_DoProtectDIBSection( X_PHYSBITMAP *physBitmap, DWORD new_
*/ */
static void X11DRV_DIB_DoCopyDIBSection(X_PHYSBITMAP *physBitmap, BOOL toDIB, static void X11DRV_DIB_DoCopyDIBSection(X_PHYSBITMAP *physBitmap, BOOL toDIB,
void *colorMap, int nColorMap, void *colorMap, int nColorMap,
Drawable dest, Drawable dest, GC gc,
DWORD xSrc, DWORD ySrc, DWORD xSrc, DWORD ySrc,
DWORD xDest, DWORD yDest, DWORD xDest, DWORD yDest,
DWORD width, DWORD height) DWORD width, DWORD height)
...@@ -4202,7 +4202,7 @@ static void X11DRV_DIB_DoCopyDIBSection(X_PHYSBITMAP *physBitmap, BOOL toDIB, ...@@ -4202,7 +4202,7 @@ static void X11DRV_DIB_DoCopyDIBSection(X_PHYSBITMAP *physBitmap, BOOL toDIB,
/* Hack for now */ /* Hack for now */
descr.drawable = dest; descr.drawable = dest;
descr.gc = BITMAP_GC(physBitmap); descr.gc = gc;
descr.xSrc = xSrc; descr.xSrc = xSrc;
descr.ySrc = ySrc; descr.ySrc = ySrc;
descr.xDest = xDest; descr.xDest = xDest;
...@@ -4280,7 +4280,7 @@ void X11DRV_DIB_CopyDIBSection(X11DRV_PDEVICE *physDevSrc, X11DRV_PDEVICE *physD ...@@ -4280,7 +4280,7 @@ void X11DRV_DIB_CopyDIBSection(X11DRV_PDEVICE *physDevSrc, X11DRV_PDEVICE *physD
} }
/* perform the copy */ /* perform the copy */
X11DRV_DIB_DoCopyDIBSection(physBitmap, FALSE, colorMap, nColorMap, X11DRV_DIB_DoCopyDIBSection(physBitmap, FALSE, colorMap, nColorMap,
physDevDst->drawable, xSrc, ySrc, physDevDst->drawable, physDevDst->gc, xSrc, ySrc,
physDevDst->org.x + xDest, physDevDst->org.y + yDest, physDevDst->org.x + xDest, physDevDst->org.y + yDest,
width, height); width, height);
/* free color mapping */ /* free color mapping */
...@@ -4299,8 +4299,8 @@ static void X11DRV_DIB_DoUpdateDIBSection(X_PHYSBITMAP *physBitmap, BOOL toDIB) ...@@ -4299,8 +4299,8 @@ static void X11DRV_DIB_DoUpdateDIBSection(X_PHYSBITMAP *physBitmap, BOOL toDIB)
GetObjectW( physBitmap->hbitmap, sizeof(bitmap), &bitmap ); GetObjectW( physBitmap->hbitmap, sizeof(bitmap), &bitmap );
X11DRV_DIB_DoCopyDIBSection(physBitmap, toDIB, X11DRV_DIB_DoCopyDIBSection(physBitmap, toDIB,
physBitmap->colorMap, physBitmap->nColorMap, physBitmap->colorMap, physBitmap->nColorMap,
physBitmap->pixmap, 0, 0, 0, 0, physBitmap->pixmap, BITMAP_GC(physBitmap),
bitmap.bmWidth, bitmap.bmHeight); 0, 0, 0, 0, bitmap.bmWidth, bitmap.bmHeight);
} }
/*********************************************************************** /***********************************************************************
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment