From 96323feab4f3cccb49cc443c35d20ef95972fe34 Mon Sep 17 00:00:00 2001 From: Johannes Anderwald Date: Mon, 26 Oct 2009 19:32:25 +0000 Subject: [PATCH] - Revert 43774 svn path=/trunk/; revision=43783 --- reactos/dll/directx/dsound_new/classfactory.c | 134 ----------------- reactos/dll/directx/dsound_new/dsound.c | 52 ------- reactos/dll/directx/dsound_new/dsound.spec | 14 -- .../dll/directx/dsound_new/dsound_new.rbuild | 19 --- reactos/dll/directx/dsound_new/precomp.h | 30 ---- reactos/dll/directx/dsound_new/stubs.c | 137 ------------------ reactos/dll/directx/dsound_new/version.rc | 14 -- 7 files changed, 400 deletions(-) delete mode 100644 reactos/dll/directx/dsound_new/classfactory.c delete mode 100644 reactos/dll/directx/dsound_new/dsound.c delete mode 100644 reactos/dll/directx/dsound_new/dsound.spec delete mode 100644 reactos/dll/directx/dsound_new/dsound_new.rbuild delete mode 100644 reactos/dll/directx/dsound_new/precomp.h delete mode 100644 reactos/dll/directx/dsound_new/stubs.c delete mode 100644 reactos/dll/directx/dsound_new/version.rc diff --git a/reactos/dll/directx/dsound_new/classfactory.c b/reactos/dll/directx/dsound_new/classfactory.c deleted file mode 100644 index c2aeea8d2a7..00000000000 --- a/reactos/dll/directx/dsound_new/classfactory.c +++ /dev/null @@ -1,134 +0,0 @@ -/* - * COPYRIGHT: See COPYING in the top level directory - * PROJECT: ReactOS Configuration of network devices - * FILE: dll/directx/dsound_new/classfactory.c - * PURPOSE: IClassFactory implementation - * - * PROGRAMMERS: Johannes Anderwald (janderwald@reactos.org) - */ - - -#include "precomp.h" - -typedef struct -{ - const IClassFactoryVtbl *lpVtbl; - LONG ref; - CLSID *rclsid; - LPFNCREATEINSTANCE lpfnCI; - const IID * riidInst; -} IClassFactoryImpl; - - -static -HRESULT -WINAPI -IClassFactory_fnQueryInterface( - LPCLASSFACTORY iface, - REFIID riid, - LPVOID *ppvObj) -{ - IClassFactoryImpl *This = (IClassFactoryImpl *)iface; - - *ppvObj = NULL; - if(IsEqualIID(riid, &IID_IUnknown) || IsEqualIID(riid, &IID_IClassFactory)) - { - *ppvObj = This; - InterlockedIncrement(&This->ref); - return S_OK; - } - return E_NOINTERFACE; -} - -static -ULONG -WINAPI -IClassFactory_fnAddRef( - LPCLASSFACTORY iface) -{ - IClassFactoryImpl *This = (IClassFactoryImpl *)iface; - ULONG refCount = InterlockedIncrement(&This->ref); - - return refCount; -} - -static -ULONG -WINAPI -IClassFactory_fnRelease( - LPCLASSFACTORY iface) -{ - IClassFactoryImpl *This = (IClassFactoryImpl *)iface; - ULONG refCount = InterlockedDecrement(&This->ref); - - if (!refCount) - { - CoTaskMemFree(This); - return 0; - } - return refCount; -} - -static -HRESULT -WINAPI -IClassFactory_fnCreateInstance( - LPCLASSFACTORY iface, - LPUNKNOWN pUnkOuter, - REFIID riid, - LPVOID *ppvObject) -{ - IClassFactoryImpl *This = (IClassFactoryImpl *)iface; - - *ppvObject = NULL; - - if ( This->riidInst==NULL || IsEqualCLSID(riid, This->riidInst) || IsEqualCLSID(riid, &IID_IUnknown) ) - { - return This->lpfnCI(pUnkOuter, riid, ppvObject); - } - - return E_NOINTERFACE; -} - -static -HRESULT -WINAPI IClassFactory_fnLockServer( - LPCLASSFACTORY iface, - BOOL fLock) -{ - //IClassFactoryImpl *This = (IClassFactoryImpl *)iface; - return E_NOTIMPL; -} - - -static const IClassFactoryVtbl dclfvt = -{ - IClassFactory_fnQueryInterface, - IClassFactory_fnAddRef, - IClassFactory_fnRelease, - IClassFactory_fnCreateInstance, - IClassFactory_fnLockServer -}; - - -IClassFactory * -IClassFactory_fnConstructor( - LPFNCREATEINSTANCE lpfnCI, - PLONG pcRefDll, - REFIID riidInst) -{ - IClassFactoryImpl* lpclf; - - lpclf = CoTaskMemAlloc(sizeof(IClassFactoryImpl)); - lpclf->ref = 1; - lpclf->lpVtbl = &dclfvt; - lpclf->lpfnCI = lpfnCI; - - if (pcRefDll) - InterlockedIncrement(pcRefDll); - lpclf->riidInst = riidInst; - - return (LPCLASSFACTORY)lpclf; -} - - diff --git a/reactos/dll/directx/dsound_new/dsound.c b/reactos/dll/directx/dsound_new/dsound.c deleted file mode 100644 index 5b1f3417b3b..00000000000 --- a/reactos/dll/directx/dsound_new/dsound.c +++ /dev/null @@ -1,52 +0,0 @@ -/* - * COPYRIGHT: See COPYING in the top level directory - * PROJECT: ReactOS Configuration of network devices - * FILE: dll/directx/dsound_new/dsound.c - * PURPOSE: Handles DSound initialization - * - * PROGRAMMERS: Johannes Anderwald (janderwald@reactos.org) - */ - -#include "precomp.h" - - -HINSTANCE dsound_hInstance; - -HRESULT -WINAPI -DllCanUnloadNow() -{ - return S_FALSE; -} - -HRESULT -WINAPI -DllGetClassObject( - REFCLSID rclsid, - REFIID riid, - LPVOID *ppv) -{ - UNIMPLEMENTED - return CLASS_E_CLASSNOTAVAILABLE; -} - -BOOL -WINAPI -DllMain( - HINSTANCE hInstDLL, - DWORD fdwReason, - LPVOID lpvReserved) -{ - switch (fdwReason) - { - case DLL_PROCESS_ATTACH: - dsound_hInstance = hInstDLL; - DisableThreadLibraryCalls(dsound_hInstance); - break; - default: - break; - } - - return TRUE; -} - diff --git a/reactos/dll/directx/dsound_new/dsound.spec b/reactos/dll/directx/dsound_new/dsound.spec deleted file mode 100644 index e4878a81692..00000000000 --- a/reactos/dll/directx/dsound_new/dsound.spec +++ /dev/null @@ -1,14 +0,0 @@ -1 stdcall DirectSoundCreate(ptr ptr ptr) -2 stdcall DirectSoundEnumerateA(ptr ptr) -3 stdcall DirectSoundEnumerateW(ptr ptr) -6 stdcall DirectSoundCaptureCreate(ptr ptr ptr) -7 stdcall DirectSoundCaptureEnumerateA(ptr ptr) -8 stdcall DirectSoundCaptureEnumerateW(ptr ptr) -9 stdcall GetDeviceID(ptr ptr) -10 stdcall DirectSoundFullDuplexCreate(ptr ptr ptr ptr long long ptr ptr ptr ptr) -11 stdcall DirectSoundCreate8(ptr ptr ptr) -12 stdcall DirectSoundCaptureCreate8(ptr ptr ptr) -@ stdcall -private DllCanUnloadNow() -@ stdcall -private DllGetClassObject(ptr ptr ptr) -@ stdcall -private DllRegisterServer() -@ stdcall -private DllUnregisterServer() diff --git a/reactos/dll/directx/dsound_new/dsound_new.rbuild b/reactos/dll/directx/dsound_new/dsound_new.rbuild deleted file mode 100644 index af785b00e02..00000000000 --- a/reactos/dll/directx/dsound_new/dsound_new.rbuild +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - . - uuid - ntdll - kernel32 - user32 - advapi32 - ole32 - winmm - dxguid - classfactory.c - dsound.c - stubs.c - version.rc - diff --git a/reactos/dll/directx/dsound_new/precomp.h b/reactos/dll/directx/dsound_new/precomp.h deleted file mode 100644 index 0e5d791cd92..00000000000 --- a/reactos/dll/directx/dsound_new/precomp.h +++ /dev/null @@ -1,30 +0,0 @@ -#ifndef PRECOMP_H__ -#define PRECOMP_H__ - -#define COBJMACROS -#define NONAMELESSUNION -#define NONAMELESSSTRUCT - -#include -#include -#include -#include -#include -#include - - -/* factory method */ -typedef HRESULT (CALLBACK *LPFNCREATEINSTANCE)(IUnknown* pUnkOuter, REFIID riid, LPVOID* ppvObject); - -/* factory table */ -typedef struct -{ - REFIID riid; - LPFNCREATEINSTANCE lpfnCI; -} INTERFACE_TABLE; - -/* globals */ -extern HINSTANCE dsound_hInstance; - - -#endif diff --git a/reactos/dll/directx/dsound_new/stubs.c b/reactos/dll/directx/dsound_new/stubs.c deleted file mode 100644 index 74b521ba836..00000000000 --- a/reactos/dll/directx/dsound_new/stubs.c +++ /dev/null @@ -1,137 +0,0 @@ -/* - * COPYRIGHT: See COPYING in the top level directory - * PROJECT: ReactOS Configuration of network devices - * FILE: dll/directx/dsound_new/stubs.c - * PURPOSE: DSound stubs - * - * PROGRAMMERS: Johannes Anderwald (janderwald@reactos.org) - */ - -#include "precomp.h" - -HRESULT -WINAPI -DirectSoundCreate( - LPCGUID lpcGUID, - LPDIRECTSOUND *ppDS, - IUnknown *pUnkOuter) -{ - UNIMPLEMENTED - return DSERR_INVALIDPARAM; -} - - -HRESULT -WINAPI -DirectSoundEnumerateA( - LPDSENUMCALLBACKA lpDSEnumCallback, - LPVOID lpContext) -{ - UNIMPLEMENTED - return DSERR_INVALIDPARAM; -} - -HRESULT -WINAPI -DirectSoundEnumerateW( - LPDSENUMCALLBACKW lpDSEnumCallback, - LPVOID lpContext ) -{ - UNIMPLEMENTED - return DSERR_INVALIDPARAM; -} - -HRESULT -WINAPI -DllRegisterServer(void) -{ - UNIMPLEMENTED - return SELFREG_E_CLASS; -} - -HRESULT -WINAPI -DllUnregisterServer(void) -{ - UNIMPLEMENTED - return SELFREG_E_CLASS; -} - -HRESULT -WINAPI -DirectSoundCaptureCreate( - LPCGUID lpcGUID, - LPDIRECTSOUNDCAPTURE *ppDSC, - LPUNKNOWN pUnkOuter) -{ - UNIMPLEMENTED - return DSERR_INVALIDPARAM; -} - -HRESULT -WINAPI -DirectSoundCaptureCreate8( - LPCGUID lpcGUID, - LPDIRECTSOUNDCAPTURE8 *ppDSC8, - LPUNKNOWN pUnkOuter) -{ - UNIMPLEMENTED - return DSERR_INVALIDPARAM; -} - -HRESULT -WINAPI -DirectSoundCreate8( - LPCGUID lpcGUID, - LPDIRECTSOUND8 *ppDS, - IUnknown *pUnkOuter) -{ - UNIMPLEMENTED - return DSERR_INVALIDPARAM; -} - -HRESULT -WINAPI -DirectSoundFullDuplexCreate( - LPCGUID pcGuidCaptureDevice, - LPCGUID pcGuidRenderDevice, - LPCDSCBUFFERDESC pcDSCBufferDesc, - LPCDSBUFFERDESC pcDSBufferDesc, - HWND hWnd, - DWORD dwLevel, - LPDIRECTSOUNDFULLDUPLEX *ppDSFD, - LPDIRECTSOUNDCAPTUREBUFFER8 *ppDSCBuffer8, - LPDIRECTSOUNDBUFFER8 *ppDSBuffer8, - LPUNKNOWN pUnkOuter) -{ - UNIMPLEMENTED - return DSERR_INVALIDPARAM; -} - -HRESULT -WINAPI -DirectSoundCaptureEnumerateA( - LPDSENUMCALLBACKA lpDSEnumCallback, - LPVOID lpContext) -{ - UNIMPLEMENTED - return DSERR_INVALIDPARAM; -} - -HRESULT -WINAPI -DirectSoundCaptureEnumerateW( - LPDSENUMCALLBACKW lpDSEnumCallback, - LPVOID lpContext) -{ - UNIMPLEMENTED - return DSERR_INVALIDPARAM; -} - -HRESULT -WINAPI -GetDeviceID(LPCGUID pGuidSrc, LPGUID pGuidDest) -{ - UNIMPLEMENTED - return DSERR_INVALIDPARAM; -} diff --git a/reactos/dll/directx/dsound_new/version.rc b/reactos/dll/directx/dsound_new/version.rc deleted file mode 100644 index 763c823296a..00000000000 --- a/reactos/dll/directx/dsound_new/version.rc +++ /dev/null @@ -1,14 +0,0 @@ -#include -#include "shlobj.h" -#include "resource.h" - -LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL - -#define REACTOS_VERSION_DLL -#define REACTOS_STR_FILE_DESCRIPTION "DirectSound\0" -#define REACTOS_STR_INTERNAL_NAME "dsound.dll\0" -#define REACTOS_STR_ORIGINAL_FILENAME "dsound.dll\0" -#define REACTOS_STR_PRODUCT_VERSION "5.3.1.904\0" -#define REACTOS_STR_FILE_VERSION "5.3.1.904\0" - -#include