gdi32: Trigger the display driver load for CreateCompatibleDC(0).
This commit is contained in:
parent
7c3bb6070a
commit
200eb1d30b
|
@ -739,7 +739,7 @@ HDC WINAPI CreateCompatibleDC( HDC hdc )
|
||||||
{
|
{
|
||||||
DC *dc, *origDC;
|
DC *dc, *origDC;
|
||||||
HDC ret;
|
HDC ret;
|
||||||
const struct gdi_dc_funcs *funcs = &null_driver;
|
const struct gdi_dc_funcs *funcs;
|
||||||
PHYSDEV physDev = NULL;
|
PHYSDEV physDev = NULL;
|
||||||
|
|
||||||
GDI_CheckNotLock();
|
GDI_CheckNotLock();
|
||||||
|
@ -751,6 +751,7 @@ HDC WINAPI CreateCompatibleDC( HDC hdc )
|
||||||
funcs = physDev->funcs;
|
funcs = physDev->funcs;
|
||||||
release_dc_ptr( origDC );
|
release_dc_ptr( origDC );
|
||||||
}
|
}
|
||||||
|
else funcs = DRIVER_load_driver( displayW );
|
||||||
|
|
||||||
if (!(dc = alloc_dc_ptr( OBJ_MEMDC ))) return 0;
|
if (!(dc = alloc_dc_ptr( OBJ_MEMDC ))) return 0;
|
||||||
|
|
||||||
|
@ -765,7 +766,7 @@ HDC WINAPI CreateCompatibleDC( HDC hdc )
|
||||||
|
|
||||||
ret = dc->hSelf;
|
ret = dc->hSelf;
|
||||||
|
|
||||||
if (!funcs->pCreateCompatibleDC( physDev, &dc->physDev ))
|
if (funcs->pCreateCompatibleDC && !funcs->pCreateCompatibleDC( physDev, &dc->physDev ))
|
||||||
{
|
{
|
||||||
WARN("creation aborted by device\n");
|
WARN("creation aborted by device\n");
|
||||||
free_dc_ptr( dc );
|
free_dc_ptr( dc );
|
||||||
|
|
Loading…
Reference in New Issue