mirror of
https://github.com/reactos/reactos.git
synced 2024-09-05 18:26:53 +00:00
partly implement NtGdiDdReenableDirectDrawObject
this give us bit more closer getting hardware accalertions working. svn path=/trunk/; revision=25977
This commit is contained in:
parent
c44e8d2c89
commit
2c81a2df18
|
@ -540,6 +540,58 @@ NtGdiDdQueryDirectDrawObject(
|
||||||
return Ret;
|
return Ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
BOOL STDCALL NtGdiDdReenableDirectDrawObject(
|
||||||
|
HANDLE hDirectDrawLocal,
|
||||||
|
BOOL *pubNewMode
|
||||||
|
)
|
||||||
|
{
|
||||||
|
BOOL Ret=FALSE;
|
||||||
|
NTSTATUS Status = FALSE;
|
||||||
|
PDD_DIRECTDRAW pDirectDraw;
|
||||||
|
|
||||||
|
if (hDirectDrawLocal == NULL)
|
||||||
|
{
|
||||||
|
return Ret;
|
||||||
|
}
|
||||||
|
|
||||||
|
pDirectDraw = GDIOBJ_LockObj(DdHandleTable, hDirectDrawLocal,
|
||||||
|
GDI_OBJECT_TYPE_DIRECTDRAW);
|
||||||
|
|
||||||
|
if (!pDirectDraw)
|
||||||
|
{
|
||||||
|
return Ret;
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* FIXME detect mode change thic code maybe are not correct
|
||||||
|
* if we call on intEnableDriver it will cause some memory leak
|
||||||
|
* we need free the alloc memory before we call on it
|
||||||
|
*/
|
||||||
|
Ret = intEnableDriver(pDirectDraw);
|
||||||
|
|
||||||
|
_SEH_TRY
|
||||||
|
{
|
||||||
|
ProbeForWrite(pubNewMode, sizeof(BOOL), 1);
|
||||||
|
*pubNewMode = Ret;
|
||||||
|
}
|
||||||
|
_SEH_HANDLE
|
||||||
|
{
|
||||||
|
Status = _SEH_GetExceptionCode();
|
||||||
|
}
|
||||||
|
_SEH_END;
|
||||||
|
if(!NT_SUCCESS(Status))
|
||||||
|
{
|
||||||
|
SetLastNtError(Status);
|
||||||
|
return Ret;
|
||||||
|
}
|
||||||
|
|
||||||
|
GDIOBJ_UnlockObjByPtr(DdHandleTable, pDirectDraw);
|
||||||
|
|
||||||
|
return Ret;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
DWORD STDCALL NtGdiDdGetDriverInfo(
|
DWORD STDCALL NtGdiDdGetDriverInfo(
|
||||||
HANDLE hDirectDrawLocal,
|
HANDLE hDirectDrawLocal,
|
||||||
|
|
|
@ -304,15 +304,6 @@ DWORD STDCALL NtGdiDdQueryMoCompStatus(
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
BOOL STDCALL NtGdiDdReenableDirectDrawObject(
|
|
||||||
HANDLE hDirectDrawLocal,
|
|
||||||
BOOL *pubNewMode
|
|
||||||
)
|
|
||||||
{
|
|
||||||
UNIMPLEMENTED
|
|
||||||
|
|
||||||
return FALSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
BOOL STDCALL NtGdiDdReleaseDC(
|
BOOL STDCALL NtGdiDdReleaseDC(
|
||||||
HANDLE hSurface
|
HANDLE hSurface
|
||||||
|
|
Loading…
Reference in a new issue