gdi32: Remove the CopyBitmap driver entry point.
This commit is contained in:
parent
91e95e125e
commit
fdc4682e31
|
@ -65,27 +65,6 @@ DWORD nulldrv_PutImage( PHYSDEV dev, HBITMAP hbitmap, HRGN clip, BITMAPINFO *inf
|
|||
return dib_driver.pPutImage( NULL, hbitmap, clip, info, bits, src, dst, rop );
|
||||
}
|
||||
|
||||
BOOL nulldrv_CopyBitmap( HBITMAP src, HBITMAP dst )
|
||||
{
|
||||
BOOL ret = TRUE;
|
||||
BITMAPOBJ *src_bmp = GDI_GetObjPtr( src, OBJ_BITMAP );
|
||||
|
||||
if (!src_bmp) return FALSE;
|
||||
if (src_bmp->dib.dsBm.bmBits)
|
||||
{
|
||||
BITMAPOBJ *dst_bmp = GDI_GetObjPtr( dst, OBJ_BITMAP );
|
||||
int stride = get_dib_stride( dst_bmp->dib.dsBm.bmWidth, dst_bmp->dib.dsBm.bmBitsPixel );
|
||||
dst_bmp->dib.dsBm.bmBits = HeapAlloc( GetProcessHeap(), 0, dst_bmp->dib.dsBm.bmHeight * stride );
|
||||
if (dst_bmp->dib.dsBm.bmBits)
|
||||
memcpy( dst_bmp->dib.dsBm.bmBits, src_bmp->dib.dsBm.bmBits, dst_bmp->dib.dsBm.bmHeight * stride );
|
||||
else
|
||||
ret = FALSE;
|
||||
GDI_ReleaseObj( dst );
|
||||
}
|
||||
GDI_ReleaseObj( src );
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
/******************************************************************************
|
||||
* CreateBitmap [GDI32.@]
|
||||
|
|
|
@ -97,7 +97,6 @@ BOOL store_brush_pattern( LOGBRUSH *brush, struct brush_pattern *pattern )
|
|||
{
|
||||
HGLOBAL hmem = 0;
|
||||
|
||||
pattern->bitmap = 0;
|
||||
pattern->info = NULL;
|
||||
pattern->bits.free = NULL;
|
||||
|
||||
|
|
|
@ -345,14 +345,6 @@ static BOOL dibdrv_DeleteDC( PHYSDEV dev )
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* dibdrv_CopyBitmap
|
||||
*/
|
||||
static BOOL dibdrv_CopyBitmap( HBITMAP src, HBITMAP dst )
|
||||
{
|
||||
return nulldrv_CopyBitmap( src, dst );
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* dibdrv_DeleteBitmap
|
||||
*/
|
||||
|
@ -439,7 +431,6 @@ const struct gdi_dc_funcs dib_driver =
|
|||
NULL, /* pChoosePixelFormat */
|
||||
dibdrv_Chord, /* pChord */
|
||||
NULL, /* pCloseFigure */
|
||||
dibdrv_CopyBitmap, /* pCopyBitmap */
|
||||
NULL, /* pCreateBitmap */
|
||||
NULL, /* pCreateCompatibleDC */
|
||||
dibdrv_CreateDC, /* pCreateDC */
|
||||
|
|
|
@ -735,7 +735,6 @@ const struct gdi_dc_funcs null_driver =
|
|||
nulldrv_ChoosePixelFormat, /* pChoosePixelFormat */
|
||||
nulldrv_Chord, /* pChord */
|
||||
nulldrv_CloseFigure, /* pCloseFigure */
|
||||
nulldrv_CopyBitmap, /* pCopyBitmap */
|
||||
nulldrv_CreateBitmap, /* pCreateBitmap */
|
||||
nulldrv_CreateCompatibleDC, /* pCreateCompatibleDC */
|
||||
nulldrv_CreateDC, /* pCreateDC */
|
||||
|
|
|
@ -47,7 +47,6 @@ static const struct gdi_dc_funcs EMFDRV_Funcs =
|
|||
NULL, /* pChoosePixelFormat */
|
||||
EMFDRV_Chord, /* pChord */
|
||||
EMFDRV_CloseFigure, /* pCloseFigure */
|
||||
NULL, /* pCopyBitmap */
|
||||
NULL, /* pCreateBitmap */
|
||||
NULL, /* pCreateCompatibleDC */
|
||||
NULL, /* pCreateDC */
|
||||
|
|
|
@ -7751,7 +7751,6 @@ static const struct gdi_dc_funcs freetype_funcs =
|
|||
NULL, /* pChoosePixelFormat */
|
||||
NULL, /* pChord */
|
||||
NULL, /* pCloseFigure */
|
||||
NULL, /* pCopyBitmap */
|
||||
NULL, /* pCreateBitmap */
|
||||
NULL, /* pCreateCompatibleDC */
|
||||
freetype_CreateDC, /* pCreateDC */
|
||||
|
|
|
@ -362,7 +362,6 @@ extern BOOL nulldrv_BeginPath( PHYSDEV dev ) DECLSPEC_HIDDEN;
|
|||
extern DWORD nulldrv_BlendImage( PHYSDEV dev, BITMAPINFO *info, const struct gdi_image_bits *bits,
|
||||
struct bitblt_coords *src, struct bitblt_coords *dst, BLENDFUNCTION func ) DECLSPEC_HIDDEN;
|
||||
extern BOOL nulldrv_CloseFigure( PHYSDEV dev ) DECLSPEC_HIDDEN;
|
||||
extern BOOL nulldrv_CopyBitmap( HBITMAP src, HBITMAP dst ) DECLSPEC_HIDDEN;
|
||||
extern BOOL nulldrv_EndPath( PHYSDEV dev ) DECLSPEC_HIDDEN;
|
||||
extern INT nulldrv_ExcludeClipRect( PHYSDEV dev, INT left, INT top, INT right, INT bottom ) DECLSPEC_HIDDEN;
|
||||
extern INT nulldrv_ExtSelectClipRgn( PHYSDEV dev, HRGN rgn, INT mode ) DECLSPEC_HIDDEN;
|
||||
|
|
|
@ -110,7 +110,6 @@ static const struct gdi_dc_funcs MFDRV_Funcs =
|
|||
NULL, /* pChoosePixelFormat */
|
||||
MFDRV_Chord, /* pChord */
|
||||
MFDRV_CloseFigure, /* pCloseFigure */
|
||||
NULL, /* pCopyBitmap */
|
||||
NULL, /* pCreateBitmap */
|
||||
MFDRV_CreateCompatibleDC, /* pCreateCompatibleDC */
|
||||
NULL, /* pCreateDC */
|
||||
|
|
|
@ -2244,7 +2244,6 @@ const struct gdi_dc_funcs path_driver =
|
|||
NULL, /* pChoosePixelFormat */
|
||||
pathdrv_Chord, /* pChord */
|
||||
pathdrv_CloseFigure, /* pCloseFigure */
|
||||
NULL, /* pCopyBitmap */
|
||||
NULL, /* pCreateBitmap */
|
||||
NULL, /* pCreateCompatibleDC */
|
||||
pathdrv_CreateDC, /* pCreateDC */
|
||||
|
|
|
@ -829,7 +829,6 @@ static const struct gdi_dc_funcs psdrv_funcs =
|
|||
NULL, /* pChoosePixelFormat */
|
||||
PSDRV_Chord, /* pChord */
|
||||
NULL, /* pCloseFigure */
|
||||
NULL, /* pCopyBitmap */
|
||||
NULL, /* pCreateBitmap */
|
||||
PSDRV_CreateCompatibleDC, /* pCreateCompatibleDC */
|
||||
PSDRV_CreateDC, /* pCreateDC */
|
||||
|
|
|
@ -193,43 +193,6 @@ BOOL X11DRV_CreateBitmap( PHYSDEV dev, HBITMAP hbitmap )
|
|||
}
|
||||
|
||||
|
||||
/****************************************************************************
|
||||
* CopyBitmap (X11DRV.@)
|
||||
*/
|
||||
BOOL X11DRV_CopyBitmap( HBITMAP src, HBITMAP dst )
|
||||
{
|
||||
X_PHYSBITMAP *phys_src, *phys_dst;
|
||||
BITMAP bitmap;
|
||||
|
||||
if (!(phys_src = X11DRV_get_phys_bitmap( src ))) return FALSE;
|
||||
if (!GetObjectW( dst, sizeof(bitmap), &bitmap )) return FALSE;
|
||||
|
||||
TRACE("%p->%p %dx%d %d bpp\n", src, dst, bitmap.bmWidth, bitmap.bmHeight, bitmap.bmBitsPixel);
|
||||
|
||||
if (!(phys_dst = X11DRV_init_phys_bitmap( dst ))) return FALSE;
|
||||
|
||||
phys_dst->depth = phys_src->depth;
|
||||
phys_dst->format = phys_src->format;
|
||||
phys_dst->trueColor = phys_src->trueColor;
|
||||
if (phys_dst->trueColor) phys_dst->color_shifts = phys_src->color_shifts;
|
||||
|
||||
wine_tsx11_lock();
|
||||
phys_dst->pixmap = XCreatePixmap( gdi_display, root_window,
|
||||
bitmap.bmWidth, bitmap.bmHeight, phys_dst->depth );
|
||||
XCopyArea( gdi_display, phys_src->pixmap, phys_dst->pixmap,
|
||||
get_bitmap_gc(phys_dst->depth), 0, 0, bitmap.bmWidth, bitmap.bmHeight, 0, 0 );
|
||||
wine_tsx11_unlock();
|
||||
|
||||
if (!phys_dst->pixmap)
|
||||
{
|
||||
WARN("Can't create Pixmap\n");
|
||||
HeapFree( GetProcessHeap(), 0, phys_dst );
|
||||
return FALSE;
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* DeleteBitmap (X11DRV.@)
|
||||
*/
|
||||
|
|
|
@ -516,7 +516,6 @@ static const struct gdi_dc_funcs x11drv_funcs =
|
|||
X11DRV_ChoosePixelFormat, /* pChoosePixelFormat */
|
||||
X11DRV_Chord, /* pChord */
|
||||
NULL, /* pCloseFigure */
|
||||
X11DRV_CopyBitmap, /* pCopyBitmap */
|
||||
X11DRV_CreateBitmap, /* pCreateBitmap */
|
||||
X11DRV_CreateCompatibleDC, /* pCreateCompatibleDC */
|
||||
X11DRV_CreateDC, /* pCreateDC */
|
||||
|
|
|
@ -3935,7 +3935,6 @@ static const struct gdi_dc_funcs glxdrv_funcs =
|
|||
glxdrv_ChoosePixelFormat, /* pChoosePixelFormat */
|
||||
NULL, /* pChord */
|
||||
NULL, /* pCloseFigure */
|
||||
NULL, /* pCopyBitmap */
|
||||
NULL, /* pCreateBitmap */
|
||||
glxdrv_CreateCompatibleDC, /* pCreateCompatibleDC */
|
||||
glxdrv_CreateDC, /* pCreateDC */
|
||||
|
|
|
@ -173,7 +173,6 @@ extern BOOL X11DRV_Arc( PHYSDEV dev, INT left, INT top, INT right,
|
|||
INT bottom, INT xstart, INT ystart, INT xend, INT yend ) DECLSPEC_HIDDEN;
|
||||
extern BOOL X11DRV_Chord( PHYSDEV dev, INT left, INT top, INT right, INT bottom,
|
||||
INT xstart, INT ystart, INT xend, INT yend ) DECLSPEC_HIDDEN;
|
||||
extern BOOL X11DRV_CopyBitmap( HBITMAP src, HBITMAP dst ) DECLSPEC_HIDDEN;
|
||||
extern BOOL X11DRV_CreateBitmap( PHYSDEV dev, HBITMAP hbitmap ) DECLSPEC_HIDDEN;
|
||||
extern BOOL X11DRV_DeleteBitmap( HBITMAP hbitmap ) DECLSPEC_HIDDEN;
|
||||
extern BOOL X11DRV_Ellipse( PHYSDEV dev, INT left, INT top, INT right, INT bottom ) DECLSPEC_HIDDEN;
|
||||
|
|
|
@ -1247,14 +1247,6 @@ static INT xrenderdrv_ExtEscape( PHYSDEV dev, INT escape, INT in_count, LPCVOID
|
|||
return dev->funcs->pExtEscape( dev, escape, in_count, in_data, out_count, out_data );
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
* xrenderdrv_CopyBitmap
|
||||
*/
|
||||
static BOOL xrenderdrv_CopyBitmap( HBITMAP src, HBITMAP dst )
|
||||
{
|
||||
return X11DRV_CopyBitmap( src, dst );
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
* xrenderdrv_CreateBitmap
|
||||
*/
|
||||
|
@ -2635,7 +2627,6 @@ static const struct gdi_dc_funcs xrender_funcs =
|
|||
NULL, /* pChoosePixelFormat */
|
||||
NULL, /* pChord */
|
||||
NULL, /* pCloseFigure */
|
||||
xrenderdrv_CopyBitmap, /* pCopyBitmap */
|
||||
xrenderdrv_CreateBitmap, /* pCreateBitmap */
|
||||
xrenderdrv_CreateCompatibleDC, /* pCreateCompatibleDC */
|
||||
xrenderdrv_CreateDC, /* pCreateDC */
|
||||
|
|
|
@ -54,7 +54,6 @@ struct gdi_image_bits
|
|||
|
||||
struct brush_pattern
|
||||
{
|
||||
HBITMAP bitmap; /* bitmap handle for DDB patterns */
|
||||
BITMAPINFO *info; /* DIB info */
|
||||
struct gdi_image_bits bits; /* DIB bits */
|
||||
UINT usage; /* color usage for DIB info */
|
||||
|
@ -73,7 +72,6 @@ struct gdi_dc_funcs
|
|||
INT (*pChoosePixelFormat)(PHYSDEV,const PIXELFORMATDESCRIPTOR *);
|
||||
BOOL (*pChord)(PHYSDEV,INT,INT,INT,INT,INT,INT,INT,INT);
|
||||
BOOL (*pCloseFigure)(PHYSDEV);
|
||||
BOOL (*pCopyBitmap)(HBITMAP,HBITMAP);
|
||||
BOOL (*pCreateBitmap)(PHYSDEV,HBITMAP);
|
||||
BOOL (*pCreateCompatibleDC)(PHYSDEV,PHYSDEV*);
|
||||
BOOL (*pCreateDC)(PHYSDEV*,LPCWSTR,LPCWSTR,LPCWSTR,const DEVMODEW*);
|
||||
|
@ -213,7 +211,7 @@ struct gdi_dc_funcs
|
|||
};
|
||||
|
||||
/* increment this when you change the DC function table */
|
||||
#define WINE_GDI_DRIVER_VERSION 28
|
||||
#define WINE_GDI_DRIVER_VERSION 29
|
||||
|
||||
#define GDI_PRIORITY_NULL_DRV 0 /* null driver */
|
||||
#define GDI_PRIORITY_FONT_DRV 100 /* any font driver */
|
||||
|
|
Loading…
Reference in New Issue