Return "default" DirectDraw driver if we have at least one driver
registered.
This commit is contained in:
parent
63ba91dc8e
commit
c429669791
@ -55,6 +55,7 @@ HRESULT WINAPI DirectDrawEnumerateExA(
|
|||||||
LPDDENUMCALLBACKEXA lpCallback, LPVOID lpContext, DWORD dwFlags)
|
LPDDENUMCALLBACKEXA lpCallback, LPVOID lpContext, DWORD dwFlags)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
|
GUID zeroGUID;
|
||||||
TRACE("(%p,%p, %08lx)\n", lpCallback, lpContext, dwFlags);
|
TRACE("(%p,%p, %08lx)\n", lpCallback, lpContext, dwFlags);
|
||||||
|
|
||||||
if (TRACE_ON(ddraw)) {
|
if (TRACE_ON(ddraw)) {
|
||||||
@ -67,7 +68,24 @@ HRESULT WINAPI DirectDrawEnumerateExA(
|
|||||||
DPRINTF("DDENUM_NONDISPLAYDEVICES ");
|
DPRINTF("DDENUM_NONDISPLAYDEVICES ");
|
||||||
DPRINTF("\n");
|
DPRINTF("\n");
|
||||||
}
|
}
|
||||||
|
if (dwFlags & DDENUM_ATTACHEDSECONDARYDEVICES) {
|
||||||
|
FIXME("no attached secondary devices supported.\n");
|
||||||
|
/*return E_FAIL;*/
|
||||||
|
}
|
||||||
|
|
||||||
|
memset(&zeroGUID,0,sizeof(zeroGUID));
|
||||||
|
|
||||||
|
/* we have at least one DDRAW driver */
|
||||||
|
if (ddraw_drivers[0]) {
|
||||||
|
if (!lpCallback(
|
||||||
|
&zeroGUID, /* FIXME: or NULL? -MM */
|
||||||
|
"WINE DirectDraw",
|
||||||
|
"display",
|
||||||
|
lpContext,
|
||||||
|
0 /* FIXME: flags not supported here */
|
||||||
|
))
|
||||||
|
return DD_OK;
|
||||||
|
}
|
||||||
/* Invoke callback for what flags we do support */
|
/* Invoke callback for what flags we do support */
|
||||||
for (i=0;i<MAX_DDRAW_DRIVERS;i++) {
|
for (i=0;i<MAX_DDRAW_DRIVERS;i++) {
|
||||||
if (!ddraw_drivers[i])
|
if (!ddraw_drivers[i])
|
||||||
@ -94,11 +112,6 @@ HRESULT WINAPI DirectDrawEnumerateExA(
|
|||||||
if (dwFlags & DDENUM_NONDISPLAYDEVICES) {
|
if (dwFlags & DDENUM_NONDISPLAYDEVICES) {
|
||||||
FIXME("no non-display devices supported.\n");
|
FIXME("no non-display devices supported.\n");
|
||||||
}
|
}
|
||||||
/* Hmm. Leave this out.
|
|
||||||
if (dwFlags & DDENUM_ATTACHEDSECONDARYDEVICES) {
|
|
||||||
FIXME("no attached secondary devices supported.\n");
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
if (dwFlags & DDENUM_DETACHEDSECONDARYDEVICES) {
|
if (dwFlags & DDENUM_DETACHEDSECONDARYDEVICES) {
|
||||||
FIXME("no detached secondary devices supported.\n");
|
FIXME("no detached secondary devices supported.\n");
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user