gdi32: Add a common header to the physdev structure.
This commit is contained in:
parent
76645c5e6d
commit
5f5c7020f3
|
@ -667,6 +667,8 @@ HDC WINAPI CreateDCW( LPCWSTR driver, LPCWSTR device, LPCWSTR output,
|
||||||
goto error;
|
goto error;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
dc->physDev->funcs = funcs;
|
||||||
|
dc->physDev->hdc = hdc;
|
||||||
dc->vis_rect.left = 0;
|
dc->vis_rect.left = 0;
|
||||||
dc->vis_rect.top = 0;
|
dc->vis_rect.top = 0;
|
||||||
dc->vis_rect.right = GetDeviceCaps( hdc, DESKTOPHORZRES );
|
dc->vis_rect.right = GetDeviceCaps( hdc, DESKTOPHORZRES );
|
||||||
|
@ -791,6 +793,8 @@ HDC WINAPI CreateCompatibleDC( HDC hdc )
|
||||||
goto error;
|
goto error;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
dc->physDev->funcs = funcs;
|
||||||
|
dc->physDev->hdc = hdc;
|
||||||
DC_InitDC( dc );
|
DC_InitDC( dc );
|
||||||
release_dc_ptr( dc );
|
release_dc_ptr( dc );
|
||||||
return ret;
|
return ret;
|
||||||
|
|
|
@ -32,6 +32,7 @@
|
||||||
|
|
||||||
typedef struct
|
typedef struct
|
||||||
{
|
{
|
||||||
|
struct gdi_physdev dev;
|
||||||
HDC hdc;
|
HDC hdc;
|
||||||
ENHMETAHEADER *emh; /* Pointer to enhanced metafile header */
|
ENHMETAHEADER *emh; /* Pointer to enhanced metafile header */
|
||||||
UINT handles_size, cur_handles;
|
UINT handles_size, cur_handles;
|
||||||
|
|
|
@ -320,6 +320,8 @@ HDC WINAPI CreateEnhMetaFileW(
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
dc->physDev = (PHYSDEV)physDev;
|
dc->physDev = (PHYSDEV)physDev;
|
||||||
|
physDev->dev.funcs = &EMFDRV_Funcs;
|
||||||
|
physDev->dev.hdc = dc->hSelf;
|
||||||
physDev->hdc = dc->hSelf;
|
physDev->hdc = dc->hSelf;
|
||||||
|
|
||||||
if(description) { /* App name\0Title\0\0 */
|
if(description) { /* App name\0Title\0\0 */
|
||||||
|
|
|
@ -72,7 +72,11 @@ typedef struct tagGDIOBJHDR
|
||||||
|
|
||||||
/* Device functions for the Wine driver interface */
|
/* Device functions for the Wine driver interface */
|
||||||
|
|
||||||
typedef struct { int opaque; } *PHYSDEV; /* PHYSDEV is an opaque pointer */
|
typedef struct gdi_physdev
|
||||||
|
{
|
||||||
|
const struct tagDC_FUNCS *funcs;
|
||||||
|
HDC hdc;
|
||||||
|
} *PHYSDEV;
|
||||||
|
|
||||||
typedef struct tagDC_FUNCS
|
typedef struct tagDC_FUNCS
|
||||||
{
|
{
|
||||||
|
|
|
@ -172,6 +172,8 @@ static DC *MFDRV_AllocMetaFile(void)
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
dc->physDev = (PHYSDEV)physDev;
|
dc->physDev = (PHYSDEV)physDev;
|
||||||
|
physDev->dev.funcs = &MFDRV_Funcs;
|
||||||
|
physDev->dev.hdc = dc->hSelf;
|
||||||
physDev->hdc = dc->hSelf;
|
physDev->hdc = dc->hSelf;
|
||||||
|
|
||||||
if (!(physDev->mh = HeapAlloc( GetProcessHeap(), 0, sizeof(*physDev->mh) )))
|
if (!(physDev->mh = HeapAlloc( GetProcessHeap(), 0, sizeof(*physDev->mh) )))
|
||||||
|
|
|
@ -32,6 +32,7 @@
|
||||||
|
|
||||||
typedef struct
|
typedef struct
|
||||||
{
|
{
|
||||||
|
struct gdi_physdev dev;
|
||||||
HDC hdc;
|
HDC hdc;
|
||||||
METAHEADER *mh; /* Pointer to metafile header */
|
METAHEADER *mh; /* Pointer to metafile header */
|
||||||
UINT handles_size, cur_handles;
|
UINT handles_size, cur_handles;
|
||||||
|
|
|
@ -351,7 +351,9 @@ typedef struct {
|
||||||
BOOL had_passthrough_rect; /* See the comment in PSDRV_Rectangle */
|
BOOL had_passthrough_rect; /* See the comment in PSDRV_Rectangle */
|
||||||
} JOB;
|
} JOB;
|
||||||
|
|
||||||
typedef struct {
|
typedef struct
|
||||||
|
{
|
||||||
|
void *reserved[2]; /* reserved for gdi */
|
||||||
HDC hdc;
|
HDC hdc;
|
||||||
PSFONT font; /* Current PS font */
|
PSFONT font; /* Current PS font */
|
||||||
DOWNLOAD *downloaded_fonts;
|
DOWNLOAD *downloaded_fonts;
|
||||||
|
|
|
@ -144,6 +144,7 @@ struct xrender_info;
|
||||||
/* X physical device */
|
/* X physical device */
|
||||||
typedef struct
|
typedef struct
|
||||||
{
|
{
|
||||||
|
void *reserved[2]; /* reserved for gdi */
|
||||||
HDC hdc;
|
HDC hdc;
|
||||||
GC gc; /* X Window GC */
|
GC gc; /* X Window GC */
|
||||||
Drawable drawable;
|
Drawable drawable;
|
||||||
|
|
Loading…
Reference in New Issue