Commit 860cf251 authored by Francois Gouget's avatar Francois Gouget Committed by Alexandre Julliard

winex11.drv: The 'lossy' parameter is always false so remove it.

parent bc2a4dbe
...@@ -1542,7 +1542,7 @@ BOOL X11DRV_PatBlt( X11DRV_PDEVICE *physDev, INT left, INT top, INT width, INT h ...@@ -1542,7 +1542,7 @@ BOOL X11DRV_PatBlt( X11DRV_PDEVICE *physDev, INT left, INT top, INT width, INT h
{ {
BOOL result; BOOL result;
X11DRV_LockDIBSection( physDev, DIB_Status_GdiMod, FALSE ); X11DRV_LockDIBSection( physDev, DIB_Status_GdiMod );
result = BITBLT_InternalStretchBlt( physDev, left, top, width, height, NULL, 0, 0, 0, 0, rop ); result = BITBLT_InternalStretchBlt( physDev, left, top, width, height, NULL, 0, 0, 0, 0, rop );
X11DRV_UnlockDIBSection( physDev, TRUE ); X11DRV_UnlockDIBSection( physDev, TRUE );
return result; return result;
...@@ -1689,9 +1689,9 @@ BOOL X11DRV_BitBlt( X11DRV_PDEVICE *physDevDst, INT xDst, INT yDst, ...@@ -1689,9 +1689,9 @@ BOOL X11DRV_BitBlt( X11DRV_PDEVICE *physDevDst, INT xDst, INT yDst,
* which may avoid a copy in some situations */ * which may avoid a copy in some situations */
} }
sDst = X11DRV_LockDIBSection( physDevDst, DIB_Status_None, FALSE ); sDst = X11DRV_LockDIBSection( physDevDst, DIB_Status_None );
if (physDevDst != physDevSrc) if (physDevDst != physDevSrc)
sSrc = X11DRV_LockDIBSection( physDevSrc, DIB_Status_None, FALSE ); sSrc = X11DRV_LockDIBSection( physDevSrc, DIB_Status_None );
else else
sSrc = sDst; sSrc = sDst;
...@@ -1740,7 +1740,7 @@ BOOL X11DRV_BitBlt( X11DRV_PDEVICE *physDevDst, INT xDst, INT yDst, ...@@ -1740,7 +1740,7 @@ BOOL X11DRV_BitBlt( X11DRV_PDEVICE *physDevDst, INT xDst, INT yDst,
goto END; goto END;
/* fall back to X server copying */ /* fall back to X server copying */
} }
X11DRV_CoerceDIBSection( physDevDst, DIB_Status_GdiMod, FALSE ); X11DRV_CoerceDIBSection( physDevDst, DIB_Status_GdiMod );
wine_tsx11_lock(); wine_tsx11_lock();
XSetFunction( gdi_display, physDevDst->gc, GXcopy ); XSetFunction( gdi_display, physDevDst->gc, GXcopy );
...@@ -1751,9 +1751,9 @@ BOOL X11DRV_BitBlt( X11DRV_PDEVICE *physDevDst, INT xDst, INT yDst, ...@@ -1751,9 +1751,9 @@ BOOL X11DRV_BitBlt( X11DRV_PDEVICE *physDevDst, INT xDst, INT yDst,
goto END; goto END;
} }
X11DRV_CoerceDIBSection( physDevDst, DIB_Status_GdiMod, FALSE ); X11DRV_CoerceDIBSection( physDevDst, DIB_Status_GdiMod );
if (physDevDst != physDevSrc) if (physDevDst != physDevSrc)
X11DRV_CoerceDIBSection( physDevSrc, DIB_Status_GdiMod, FALSE ); X11DRV_CoerceDIBSection( physDevSrc, DIB_Status_GdiMod );
result = BITBLT_InternalStretchBlt( physDevDst, xDst, yDst, width, height, result = BITBLT_InternalStretchBlt( physDevDst, xDst, yDst, width, height,
physDevSrc, xSrc, ySrc, width, height, rop ); physDevSrc, xSrc, ySrc, width, height, rop );
...@@ -1777,9 +1777,9 @@ BOOL X11DRV_StretchBlt( X11DRV_PDEVICE *physDevDst, INT xDst, INT yDst, ...@@ -1777,9 +1777,9 @@ BOOL X11DRV_StretchBlt( X11DRV_PDEVICE *physDevDst, INT xDst, INT yDst,
{ {
BOOL result; BOOL result;
X11DRV_LockDIBSection( physDevDst, DIB_Status_GdiMod, FALSE ); X11DRV_LockDIBSection( physDevDst, DIB_Status_GdiMod );
if (physDevDst != physDevSrc) if (physDevDst != physDevSrc)
X11DRV_LockDIBSection( physDevSrc, DIB_Status_GdiMod, FALSE ); X11DRV_LockDIBSection( physDevSrc, DIB_Status_GdiMod );
result = BITBLT_InternalStretchBlt( physDevDst, xDst, yDst, widthDst, heightDst, result = BITBLT_InternalStretchBlt( physDevDst, xDst, yDst, widthDst, heightDst,
physDevSrc, xSrc, ySrc, widthSrc, heightSrc, rop ); physDevSrc, xSrc, ySrc, widthSrc, heightSrc, rop );
......
...@@ -97,8 +97,8 @@ enum Rle_EscapeCodes ...@@ -97,8 +97,8 @@ enum Rle_EscapeCodes
}; };
static INT X11DRV_DIB_Coerce(X_PHYSBITMAP *,INT,BOOL); static INT X11DRV_DIB_Coerce(X_PHYSBITMAP *,INT);
static INT X11DRV_DIB_Lock(X_PHYSBITMAP *,INT,BOOL); static INT X11DRV_DIB_Lock(X_PHYSBITMAP *,INT);
static void X11DRV_DIB_Unlock(X_PHYSBITMAP *,BOOL); static void X11DRV_DIB_Unlock(X_PHYSBITMAP *,BOOL);
/* /*
...@@ -3799,7 +3799,7 @@ INT X11DRV_SetDIBitsToDevice( X11DRV_PDEVICE *physDev, INT xDest, INT yDest, DWO ...@@ -3799,7 +3799,7 @@ INT X11DRV_SetDIBitsToDevice( X11DRV_PDEVICE *physDev, INT xDest, INT yDest, DWO
if (!cx || !cy) return lines; if (!cx || !cy) return lines;
/* Update the pixmap from the DIB section */ /* Update the pixmap from the DIB section */
X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod, FALSE); X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod);
X11DRV_SetupGCForText( physDev ); /* To have the correct colors */ X11DRV_SetupGCForText( physDev ); /* To have the correct colors */
wine_tsx11_lock(); wine_tsx11_lock();
...@@ -3939,7 +3939,7 @@ INT X11DRV_SetDIBits( X11DRV_PDEVICE *physDev, HBITMAP hbitmap, UINT startscan, ...@@ -3939,7 +3939,7 @@ INT X11DRV_SetDIBits( X11DRV_PDEVICE *physDev, HBITMAP hbitmap, UINT startscan,
descr.height = lines; descr.height = lines;
descr.useShm = FALSE; descr.useShm = FALSE;
descr.dibpitch = ((descr.infoWidth * descr.infoBpp + 31) &~31) / 8; descr.dibpitch = ((descr.infoWidth * descr.infoBpp + 31) &~31) / 8;
X11DRV_DIB_Lock( physBitmap, DIB_Status_GdiMod, FALSE ); X11DRV_DIB_Lock( physBitmap, DIB_Status_GdiMod );
result = X11DRV_DIB_SetImageBits( &descr ); result = X11DRV_DIB_SetImageBits( &descr );
X11DRV_DIB_Unlock( physBitmap, TRUE ); X11DRV_DIB_Unlock( physBitmap, TRUE );
...@@ -4069,7 +4069,7 @@ INT X11DRV_GetDIBits( X11DRV_PDEVICE *physDev, HBITMAP hbitmap, UINT startscan, ...@@ -4069,7 +4069,7 @@ INT X11DRV_GetDIBits( X11DRV_PDEVICE *physDev, HBITMAP hbitmap, UINT startscan,
descr.dibpitch = (obj_size == sizeof(DIBSECTION)) ? dib.dsBm.bmWidthBytes descr.dibpitch = (obj_size == sizeof(DIBSECTION)) ? dib.dsBm.bmWidthBytes
: (((descr.infoWidth * descr.infoBpp + 31) &~31) / 8); : (((descr.infoWidth * descr.infoBpp + 31) &~31) / 8);
X11DRV_DIB_Lock( physBitmap, DIB_Status_GdiMod, FALSE ); X11DRV_DIB_Lock( physBitmap, DIB_Status_GdiMod );
X11DRV_DIB_GetImageBits( &descr ); X11DRV_DIB_GetImageBits( &descr );
X11DRV_DIB_Unlock( physBitmap, TRUE ); X11DRV_DIB_Unlock( physBitmap, TRUE );
...@@ -4292,13 +4292,13 @@ static LONG CALLBACK X11DRV_DIB_FaultHandler( PEXCEPTION_POINTERS ep ) ...@@ -4292,13 +4292,13 @@ static LONG CALLBACK X11DRV_DIB_FaultHandler( PEXCEPTION_POINTERS ep )
if (!found) return EXCEPTION_CONTINUE_SEARCH; if (!found) return EXCEPTION_CONTINUE_SEARCH;
X11DRV_DIB_Lock( physBitmap, DIB_Status_None, FALSE ); X11DRV_DIB_Lock( physBitmap, DIB_Status_None );
if (ep->ExceptionRecord->ExceptionInformation[0] == EXCEPTION_WRITE_FAULT) { if (ep->ExceptionRecord->ExceptionInformation[0] == EXCEPTION_WRITE_FAULT) {
/* the app tried to write the DIB bits */ /* the app tried to write the DIB bits */
X11DRV_DIB_Coerce( physBitmap, DIB_Status_AppMod, FALSE ); X11DRV_DIB_Coerce( physBitmap, DIB_Status_AppMod);
} else { } else {
/* the app tried to read the DIB bits */ /* the app tried to read the DIB bits */
X11DRV_DIB_Coerce( physBitmap, DIB_Status_InSync, FALSE ); X11DRV_DIB_Coerce( physBitmap, DIB_Status_InSync);
} }
X11DRV_DIB_Unlock( physBitmap, TRUE ); X11DRV_DIB_Unlock( physBitmap, TRUE );
...@@ -4308,7 +4308,7 @@ static LONG CALLBACK X11DRV_DIB_FaultHandler( PEXCEPTION_POINTERS ep ) ...@@ -4308,7 +4308,7 @@ static LONG CALLBACK X11DRV_DIB_FaultHandler( PEXCEPTION_POINTERS ep )
/*********************************************************************** /***********************************************************************
* X11DRV_DIB_Coerce * X11DRV_DIB_Coerce
*/ */
static INT X11DRV_DIB_Coerce(X_PHYSBITMAP *physBitmap, INT req, BOOL lossy) static INT X11DRV_DIB_Coerce(X_PHYSBITMAP *physBitmap, INT req)
{ {
INT ret = DIB_Status_None; INT ret = DIB_Status_None;
...@@ -4340,11 +4340,9 @@ static INT X11DRV_DIB_Coerce(X_PHYSBITMAP *physBitmap, INT req, BOOL lossy) ...@@ -4340,11 +4340,9 @@ static INT X11DRV_DIB_Coerce(X_PHYSBITMAP *physBitmap, INT req, BOOL lossy)
case DIB_Status_AppMod: case DIB_Status_AppMod:
TRACE("GdiMod requested in status AppMod\n" ); TRACE("GdiMod requested in status AppMod\n" );
if (!lossy) {
/* make it readonly to avoid app changing data while we copy */ /* make it readonly to avoid app changing data while we copy */
X11DRV_DIB_DoProtectDIBSection( physBitmap, PAGE_READONLY ); X11DRV_DIB_DoProtectDIBSection( physBitmap, PAGE_READONLY );
X11DRV_DIB_DoUpdateDIBSection( physBitmap, FALSE ); X11DRV_DIB_DoUpdateDIBSection( physBitmap, FALSE );
}
X11DRV_DIB_DoProtectDIBSection( physBitmap, PAGE_NOACCESS ); X11DRV_DIB_DoProtectDIBSection( physBitmap, PAGE_NOACCESS );
physBitmap->p_status = DIB_Status_AppMod; physBitmap->p_status = DIB_Status_AppMod;
physBitmap->status = DIB_Status_GdiMod; physBitmap->status = DIB_Status_GdiMod;
...@@ -4364,10 +4362,8 @@ static INT X11DRV_DIB_Coerce(X_PHYSBITMAP *physBitmap, INT req, BOOL lossy) ...@@ -4364,10 +4362,8 @@ static INT X11DRV_DIB_Coerce(X_PHYSBITMAP *physBitmap, INT req, BOOL lossy)
case DIB_Status_GdiMod: case DIB_Status_GdiMod:
TRACE("InSync requested in status GdiMod\n" ); TRACE("InSync requested in status GdiMod\n" );
if (!lossy) {
X11DRV_DIB_DoProtectDIBSection( physBitmap, PAGE_READWRITE ); X11DRV_DIB_DoProtectDIBSection( physBitmap, PAGE_READWRITE );
X11DRV_DIB_DoUpdateDIBSection( physBitmap, TRUE ); X11DRV_DIB_DoUpdateDIBSection( physBitmap, TRUE );
}
X11DRV_DIB_DoProtectDIBSection( physBitmap, PAGE_READONLY ); X11DRV_DIB_DoProtectDIBSection( physBitmap, PAGE_READONLY );
physBitmap->status = DIB_Status_InSync; physBitmap->status = DIB_Status_InSync;
break; break;
...@@ -4398,7 +4394,7 @@ static INT X11DRV_DIB_Coerce(X_PHYSBITMAP *physBitmap, INT req, BOOL lossy) ...@@ -4398,7 +4394,7 @@ static INT X11DRV_DIB_Coerce(X_PHYSBITMAP *physBitmap, INT req, BOOL lossy)
case DIB_Status_GdiMod: case DIB_Status_GdiMod:
TRACE("AppMod requested in status GdiMod\n" ); TRACE("AppMod requested in status GdiMod\n" );
X11DRV_DIB_DoProtectDIBSection( physBitmap, PAGE_READWRITE ); X11DRV_DIB_DoProtectDIBSection( physBitmap, PAGE_READWRITE );
if (!lossy) X11DRV_DIB_DoUpdateDIBSection( physBitmap, TRUE ); X11DRV_DIB_DoUpdateDIBSection( physBitmap, TRUE );
physBitmap->status = DIB_Status_AppMod; physBitmap->status = DIB_Status_AppMod;
break; break;
...@@ -4425,7 +4421,7 @@ static INT X11DRV_DIB_Coerce(X_PHYSBITMAP *physBitmap, INT req, BOOL lossy) ...@@ -4425,7 +4421,7 @@ static INT X11DRV_DIB_Coerce(X_PHYSBITMAP *physBitmap, INT req, BOOL lossy)
/*********************************************************************** /***********************************************************************
* X11DRV_DIB_Lock * X11DRV_DIB_Lock
*/ */
static INT X11DRV_DIB_Lock(X_PHYSBITMAP *physBitmap, INT req, BOOL lossy) static INT X11DRV_DIB_Lock(X_PHYSBITMAP *physBitmap, INT req)
{ {
INT ret = DIB_Status_None; INT ret = DIB_Status_None;
...@@ -4434,7 +4430,7 @@ static INT X11DRV_DIB_Lock(X_PHYSBITMAP *physBitmap, INT req, BOOL lossy) ...@@ -4434,7 +4430,7 @@ static INT X11DRV_DIB_Lock(X_PHYSBITMAP *physBitmap, INT req, BOOL lossy)
EnterCriticalSection(&physBitmap->lock); EnterCriticalSection(&physBitmap->lock);
ret = physBitmap->status; ret = physBitmap->status;
if (req != DIB_Status_None) if (req != DIB_Status_None)
X11DRV_DIB_Coerce(physBitmap, req, lossy); X11DRV_DIB_Coerce(physBitmap, req);
return ret; return ret;
} }
...@@ -4499,19 +4495,19 @@ static void X11DRV_DIB_Unlock(X_PHYSBITMAP *physBitmap, BOOL commit) ...@@ -4499,19 +4495,19 @@ static void X11DRV_DIB_Unlock(X_PHYSBITMAP *physBitmap, BOOL commit)
/*********************************************************************** /***********************************************************************
* X11DRV_CoerceDIBSection * X11DRV_CoerceDIBSection
*/ */
INT X11DRV_CoerceDIBSection(X11DRV_PDEVICE *physDev, INT req, BOOL lossy) INT X11DRV_CoerceDIBSection(X11DRV_PDEVICE *physDev, INT req)
{ {
if (!physDev || !physDev->bitmap) return DIB_Status_None; if (!physDev || !physDev->bitmap) return DIB_Status_None;
return X11DRV_DIB_Coerce(physDev->bitmap, req, lossy); return X11DRV_DIB_Coerce(physDev->bitmap, req);
} }
/*********************************************************************** /***********************************************************************
* X11DRV_LockDIBSection * X11DRV_LockDIBSection
*/ */
INT X11DRV_LockDIBSection(X11DRV_PDEVICE *physDev, INT req, BOOL lossy) INT X11DRV_LockDIBSection(X11DRV_PDEVICE *physDev, INT req)
{ {
if (!physDev || !physDev->bitmap) return DIB_Status_None; if (!physDev || !physDev->bitmap) return DIB_Status_None;
return X11DRV_DIB_Lock(physDev->bitmap, req, lossy); return X11DRV_DIB_Lock(physDev->bitmap, req);
} }
/*********************************************************************** /***********************************************************************
...@@ -4656,7 +4652,7 @@ void X11DRV_DIB_DeleteDIBSection(X_PHYSBITMAP *physBitmap, DIBSECTION *dib) ...@@ -4656,7 +4652,7 @@ void X11DRV_DIB_DeleteDIBSection(X_PHYSBITMAP *physBitmap, DIBSECTION *dib)
} }
if (dib->dshSection) if (dib->dshSection)
X11DRV_DIB_Coerce(physBitmap, DIB_Status_InSync, FALSE); X11DRV_DIB_Coerce(physBitmap, DIB_Status_InSync);
if (physBitmap->image) if (physBitmap->image)
{ {
...@@ -4704,7 +4700,7 @@ UINT X11DRV_SetDIBColorTable( X11DRV_PDEVICE *physDev, UINT start, UINT count, c ...@@ -4704,7 +4700,7 @@ UINT X11DRV_SetDIBColorTable( X11DRV_PDEVICE *physDev, UINT start, UINT count, c
* FIXME we need to recalculate the pen, brush, text and bkgnd pixels here, * FIXME we need to recalculate the pen, brush, text and bkgnd pixels here,
* at least for a 1 bpp dibsection * at least for a 1 bpp dibsection
*/ */
X11DRV_DIB_Lock( physBitmap, DIB_Status_AppMod, FALSE ); X11DRV_DIB_Lock( physBitmap, DIB_Status_AppMod );
X11DRV_DIB_GenColorMap( physDev, physBitmap->colorMap, DIB_RGB_COLORS, X11DRV_DIB_GenColorMap( physDev, physBitmap->colorMap, DIB_RGB_COLORS,
dib.dsBm.bmBitsPixel, dib.dsBm.bmBitsPixel,
TRUE, colors, start, end ); TRUE, colors, start, end );
......
...@@ -335,7 +335,7 @@ X11DRV_LineTo( X11DRV_PDEVICE *physDev, INT x, INT y ) ...@@ -335,7 +335,7 @@ X11DRV_LineTo( X11DRV_PDEVICE *physDev, INT x, INT y )
if (X11DRV_SetupGCForPen( physDev )) { if (X11DRV_SetupGCForPen( physDev )) {
/* Update the pixmap from the DIB section */ /* Update the pixmap from the DIB section */
X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod, FALSE); X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod);
GetCurrentPositionEx( physDev->hdc, &pt[0] ); GetCurrentPositionEx( physDev->hdc, &pt[0] );
pt[1].x = x; pt[1].x = x;
...@@ -431,7 +431,7 @@ X11DRV_DrawArc( X11DRV_PDEVICE *physDev, INT left, INT top, INT right, ...@@ -431,7 +431,7 @@ X11DRV_DrawArc( X11DRV_PDEVICE *physDev, INT left, INT top, INT right,
if (idiff_angle <= 0) idiff_angle += 360 * 64; if (idiff_angle <= 0) idiff_angle += 360 * 64;
/* Update the pixmap from the DIB section */ /* Update the pixmap from the DIB section */
X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod, FALSE); X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod);
/* Fill arc with brush if Chord() or Pie() */ /* Fill arc with brush if Chord() or Pie() */
...@@ -591,7 +591,7 @@ X11DRV_Ellipse( X11DRV_PDEVICE *physDev, INT left, INT top, INT right, INT botto ...@@ -591,7 +591,7 @@ X11DRV_Ellipse( X11DRV_PDEVICE *physDev, INT left, INT top, INT right, INT botto
physDev->pen.width = width; physDev->pen.width = width;
/* Update the pixmap from the DIB section */ /* Update the pixmap from the DIB section */
X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod, FALSE); X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod);
if (X11DRV_SetupGCForBrush( physDev )) if (X11DRV_SetupGCForBrush( physDev ))
{ {
...@@ -660,7 +660,7 @@ X11DRV_Rectangle(X11DRV_PDEVICE *physDev, INT left, INT top, INT right, INT bott ...@@ -660,7 +660,7 @@ X11DRV_Rectangle(X11DRV_PDEVICE *physDev, INT left, INT top, INT right, INT bott
physDev->pen.linejoin = PS_JOIN_MITER; physDev->pen.linejoin = PS_JOIN_MITER;
/* Update the pixmap from the DIB section */ /* Update the pixmap from the DIB section */
X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod, FALSE); X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod);
if ((rc.right > rc.left + width) && (rc.bottom > rc.top + width)) if ((rc.right > rc.left + width) && (rc.bottom > rc.top + width))
{ {
...@@ -747,7 +747,7 @@ X11DRV_RoundRect( X11DRV_PDEVICE *physDev, INT left, INT top, INT right, ...@@ -747,7 +747,7 @@ X11DRV_RoundRect( X11DRV_PDEVICE *physDev, INT left, INT top, INT right,
physDev->pen.endcap = PS_ENDCAP_SQUARE; physDev->pen.endcap = PS_ENDCAP_SQUARE;
/* Update the pixmap from the DIB section */ /* Update the pixmap from the DIB section */
X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod, FALSE); X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod);
if (X11DRV_SetupGCForBrush( physDev )) if (X11DRV_SetupGCForBrush( physDev ))
{ {
...@@ -918,7 +918,7 @@ X11DRV_SetPixel( X11DRV_PDEVICE *physDev, INT x, INT y, COLORREF color ) ...@@ -918,7 +918,7 @@ X11DRV_SetPixel( X11DRV_PDEVICE *physDev, INT x, INT y, COLORREF color )
pixel = X11DRV_PALETTE_ToPhysical( physDev, color ); pixel = X11DRV_PALETTE_ToPhysical( physDev, color );
/* Update the pixmap from the DIB section */ /* Update the pixmap from the DIB section */
X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod, FALSE); X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod);
/* inefficient but simple... */ /* inefficient but simple... */
wine_tsx11_lock(); wine_tsx11_lock();
...@@ -952,7 +952,7 @@ X11DRV_GetPixel( X11DRV_PDEVICE *physDev, INT x, INT y ) ...@@ -952,7 +952,7 @@ X11DRV_GetPixel( X11DRV_PDEVICE *physDev, INT x, INT y )
LPtoDP( physDev->hdc, &pt, 1 ); LPtoDP( physDev->hdc, &pt, 1 );
/* Update the pixmap from the DIB section */ /* Update the pixmap from the DIB section */
X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod, FALSE); X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod);
wine_tsx11_lock(); wine_tsx11_lock();
if (memdc) if (memdc)
...@@ -1002,7 +1002,7 @@ X11DRV_PaintRgn( X11DRV_PDEVICE *physDev, HRGN hrgn ) ...@@ -1002,7 +1002,7 @@ X11DRV_PaintRgn( X11DRV_PDEVICE *physDev, HRGN hrgn )
rect[i].y += physDev->dc_rect.top; rect[i].y += physDev->dc_rect.top;
} }
X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod, FALSE); X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod);
wine_tsx11_lock(); wine_tsx11_lock();
XFillRectangles( gdi_display, physDev->drawable, physDev->gc, rect, data->rdh.nCount ); XFillRectangles( gdi_display, physDev->drawable, physDev->gc, rect, data->rdh.nCount );
wine_tsx11_unlock(); wine_tsx11_unlock();
...@@ -1036,7 +1036,7 @@ X11DRV_Polyline( X11DRV_PDEVICE *physDev, const POINT* pt, INT count ) ...@@ -1036,7 +1036,7 @@ X11DRV_Polyline( X11DRV_PDEVICE *physDev, const POINT* pt, INT count )
if (X11DRV_SetupGCForPen ( physDev )) if (X11DRV_SetupGCForPen ( physDev ))
{ {
X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod, FALSE); X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod);
wine_tsx11_lock(); wine_tsx11_lock();
XDrawLines( gdi_display, physDev->drawable, physDev->gc, XDrawLines( gdi_display, physDev->drawable, physDev->gc,
points, count, CoordModeOrigin ); points, count, CoordModeOrigin );
...@@ -1074,7 +1074,7 @@ X11DRV_Polygon( X11DRV_PDEVICE *physDev, const POINT* pt, INT count ) ...@@ -1074,7 +1074,7 @@ X11DRV_Polygon( X11DRV_PDEVICE *physDev, const POINT* pt, INT count )
points[count] = points[0]; points[count] = points[0];
/* Update the pixmap from the DIB section */ /* Update the pixmap from the DIB section */
X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod, FALSE); X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod);
if (X11DRV_SetupGCForBrush( physDev )) if (X11DRV_SetupGCForBrush( physDev ))
{ {
...@@ -1125,7 +1125,7 @@ X11DRV_PolyPolygon( X11DRV_PDEVICE *physDev, const POINT* pt, const INT* counts, ...@@ -1125,7 +1125,7 @@ X11DRV_PolyPolygon( X11DRV_PDEVICE *physDev, const POINT* pt, const INT* counts,
XPoint *points; XPoint *points;
/* Update the pixmap from the DIB section */ /* Update the pixmap from the DIB section */
X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod, FALSE); X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod);
for (i = 0; i < polygons; i++) if (counts[i] > max) max = counts[i]; for (i = 0; i < polygons; i++) if (counts[i] > max) max = counts[i];
if (!(points = HeapAlloc( GetProcessHeap(), 0, sizeof(XPoint) * (max+1) ))) if (!(points = HeapAlloc( GetProcessHeap(), 0, sizeof(XPoint) * (max+1) )))
...@@ -1171,7 +1171,7 @@ X11DRV_PolyPolyline( X11DRV_PDEVICE *physDev, const POINT* pt, const DWORD* coun ...@@ -1171,7 +1171,7 @@ X11DRV_PolyPolyline( X11DRV_PDEVICE *physDev, const POINT* pt, const DWORD* coun
XPoint *points; XPoint *points;
/* Update the pixmap from the DIB section */ /* Update the pixmap from the DIB section */
X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod, FALSE); X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod);
for (i = 0; i < polylines; i++) if (counts[i] > max) max = counts[i]; for (i = 0; i < polylines; i++) if (counts[i] > max) max = counts[i];
if (!(points = HeapAlloc( GetProcessHeap(), 0, sizeof(XPoint) * max ))) if (!(points = HeapAlloc( GetProcessHeap(), 0, sizeof(XPoint) * max )))
...@@ -1310,7 +1310,7 @@ X11DRV_ExtFloodFill( X11DRV_PDEVICE *physDev, INT x, INT y, COLORREF color, ...@@ -1310,7 +1310,7 @@ X11DRV_ExtFloodFill( X11DRV_PDEVICE *physDev, INT x, INT y, COLORREF color,
unsigned long pixel = X11DRV_PALETTE_ToPhysical( physDev, color ); unsigned long pixel = X11DRV_PALETTE_ToPhysical( physDev, color );
/* Update the pixmap from the DIB section */ /* Update the pixmap from the DIB section */
X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod, FALSE); X11DRV_LockDIBSection(physDev, DIB_Status_GdiMod);
/* ROP mode is always GXcopy for flood-fill */ /* ROP mode is always GXcopy for flood-fill */
wine_tsx11_lock(); wine_tsx11_lock();
......
...@@ -432,7 +432,7 @@ INT X11DRV_ExtEscape( X11DRV_PDEVICE *physDev, INT escape, INT in_count, LPCVOID ...@@ -432,7 +432,7 @@ INT X11DRV_ExtEscape( X11DRV_PDEVICE *physDev, INT escape, INT in_count, LPCVOID
case X11DRV_SYNC_PIXMAP: case X11DRV_SYNC_PIXMAP:
if(physDev->bitmap) if(physDev->bitmap)
{ {
X11DRV_CoerceDIBSection(physDev, DIB_Status_GdiMod, FALSE); X11DRV_CoerceDIBSection(physDev, DIB_Status_GdiMod);
return TRUE; return TRUE;
} }
return FALSE; return FALSE;
......
...@@ -75,7 +75,7 @@ X11DRV_ExtTextOut( X11DRV_PDEVICE *physDev, INT x, INT y, UINT flags, ...@@ -75,7 +75,7 @@ X11DRV_ExtTextOut( X11DRV_PDEVICE *physDev, INT x, INT y, UINT flags,
if (flags & ETO_OPAQUE) if (flags & ETO_OPAQUE)
{ {
X11DRV_LockDIBSection( physDev, DIB_Status_GdiMod, FALSE ); X11DRV_LockDIBSection( physDev, DIB_Status_GdiMod );
dibUpdateFlag = TRUE; dibUpdateFlag = TRUE;
wine_tsx11_lock(); wine_tsx11_lock();
XSetForeground( gdi_display, physDev->gc, physDev->backgroundPixel ); XSetForeground( gdi_display, physDev->gc, physDev->backgroundPixel );
...@@ -105,7 +105,7 @@ X11DRV_ExtTextOut( X11DRV_PDEVICE *physDev, INT x, INT y, UINT flags, ...@@ -105,7 +105,7 @@ X11DRV_ExtTextOut( X11DRV_PDEVICE *physDev, INT x, INT y, UINT flags,
if (!dibUpdateFlag) if (!dibUpdateFlag)
{ {
X11DRV_LockDIBSection( physDev, DIB_Status_GdiMod, FALSE ); X11DRV_LockDIBSection( physDev, DIB_Status_GdiMod );
dibUpdateFlag = TRUE; dibUpdateFlag = TRUE;
} }
......
...@@ -421,8 +421,8 @@ typedef struct { ...@@ -421,8 +421,8 @@ typedef struct {
extern const dib_conversions dib_normal, dib_src_byteswap, dib_dst_byteswap; extern const dib_conversions dib_normal, dib_src_byteswap, dib_dst_byteswap;
extern INT X11DRV_DIB_MaskToShift(DWORD mask); extern INT X11DRV_DIB_MaskToShift(DWORD mask);
extern INT X11DRV_CoerceDIBSection(X11DRV_PDEVICE *physDev,INT,BOOL); extern INT X11DRV_CoerceDIBSection(X11DRV_PDEVICE *physDev,INT);
extern INT X11DRV_LockDIBSection(X11DRV_PDEVICE *physDev,INT,BOOL); extern INT X11DRV_LockDIBSection(X11DRV_PDEVICE *physDev,INT);
extern void X11DRV_UnlockDIBSection(X11DRV_PDEVICE *physDev,BOOL); extern void X11DRV_UnlockDIBSection(X11DRV_PDEVICE *physDev,BOOL);
extern void X11DRV_DIB_DeleteDIBSection(X_PHYSBITMAP *physBitmap, DIBSECTION *dib); extern void X11DRV_DIB_DeleteDIBSection(X_PHYSBITMAP *physBitmap, DIBSECTION *dib);
......
...@@ -1162,7 +1162,7 @@ BOOL X11DRV_XRender_ExtTextOut( X11DRV_PDEVICE *physDev, INT x, INT y, UINT flag ...@@ -1162,7 +1162,7 @@ BOOL X11DRV_XRender_ExtTextOut( X11DRV_PDEVICE *physDev, INT x, INT y, UINT flag
XChangeGC( gdi_display, physDev->gc, GCFunction | GCBackground | GCFillStyle, &xgcval ); XChangeGC( gdi_display, physDev->gc, GCFunction | GCBackground | GCFillStyle, &xgcval );
wine_tsx11_unlock(); wine_tsx11_unlock();
X11DRV_LockDIBSection( physDev, DIB_Status_GdiMod, FALSE ); X11DRV_LockDIBSection( physDev, DIB_Status_GdiMod );
if(physDev->depth == 1) { if(physDev->depth == 1) {
if((physDev->textPixel & 0xffffff) == 0) { if((physDev->textPixel & 0xffffff) == 0) {
......
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