From b2c6d0e0d914a6fa06da110c130f6d721aa138cc Mon Sep 17 00:00:00 2001 From: Magnus Olsen Date: Fri, 29 Jul 2005 17:11:11 +0000 Subject: [PATCH] Implement GdiEntry14 (party tested see older commit msg) svn path=/trunk/; revision=16875 --- reactos/lib/gdi32/misc/gdientry.c | 39 +++++++++++++++++++++++++++++++ reactos/lib/gdi32/misc/stubs.c | 18 -------------- 2 files changed, 39 insertions(+), 18 deletions(-) diff --git a/reactos/lib/gdi32/misc/gdientry.c b/reactos/lib/gdi32/misc/gdientry.c index ef6b7d1e7ca..12a58b3c474 100644 --- a/reactos/lib/gdi32/misc/gdientry.c +++ b/reactos/lib/gdi32/misc/gdientry.c @@ -91,6 +91,9 @@ DdCreateDirectDrawObject(LPDDRAWI_DIRECTDRAW_GBL pDirectDrawGlobal, return TRUE; } + + + /* * @implemented * @@ -116,6 +119,8 @@ DdDeleteDirectDrawObject(LPDDRAWI_DIRECTDRAW_GBL pDirectDrawGlobal) } + + /* * @implemented * @@ -171,6 +176,8 @@ LPDDRAWI_DDRAWSURFACE_LCL pSurfaceLocal return NtGdiDdReleaseDC((HANDLE) pSurfaceLocal->hDDSurface); } + + /* * @implemented * @@ -193,6 +200,10 @@ DdReenableDirectDrawObject(LPDDRAWI_DIRECTDRAW_GBL pDirectDrawGlobal, return NtGdiDdReenableDirectDrawObject((HANDLE)pDirectDrawGlobal->hDD, pbNewMode); } + + + + /* * @implemented * @@ -218,6 +229,34 @@ DdQueryDisplaySettingsUniqueness() return RemberDdQueryDisplaySettingsUniquenessID; } +/* + * @implemented + * + * GDIEntry 14 + */ +HANDLE +STDCALL +DdGetDxHandle(LPDDRAWI_DIRECTDRAW_LCL pDDraw, + LPDDRAWI_DDRAWSURFACE_LCL pSurface, + BOOL bRelease) +{ + if (pSurface) + { + return ((HANDLE) NtGdiDdGetDxHandle(NULL, (HANDLE)pSurface->hDDSurface, bRelease)); + } + + + if (!pDDraw->lpGbl->hDD) + { + if (!pDirectDrawGlobalInternal->hDD) + { + return FALSE; + } + return ((HANDLE) NtGdiDdGetDxHandle( (HANDLE) pDirectDrawGlobalInternal->hDD, (HANDLE) pSurface->hDDSurface, bRelease)); + } + + return ((HANDLE) NtGdiDdGetDxHandle((HANDLE)pDDraw->lpGbl->hDD, (HANDLE) pSurface->hDDSurface, bRelease)); +} /* * @implemented diff --git a/reactos/lib/gdi32/misc/stubs.c b/reactos/lib/gdi32/misc/stubs.c index 8fb256e8890..da33b8ddfac 100644 --- a/reactos/lib/gdi32/misc/stubs.c +++ b/reactos/lib/gdi32/misc/stubs.c @@ -3938,24 +3938,6 @@ LPDDRAWI_DDRAWSURFACE_LCL pSurfaceTo } -/* - * @unimplemented - */ -HANDLE STDCALL DdGetDxHandle( -LPDDRAWI_DIRECTDRAW_LCL pDDraw, -LPDDRAWI_DDRAWSURFACE_LCL pSurface, -BOOL bRelease -) -{ - UNIMPLEMENTED; - SetLastError(ERROR_CALL_NOT_IMPLEMENTED); - return 0; -} - - - - - /* * @unimplemented */