From 5d870f5ba6cc89adf0f3429599cb19b253607cf2 Mon Sep 17 00:00:00 2001 From: Amine Khaldi Date: Thu, 8 Mar 2018 13:36:52 +0100 Subject: [PATCH] [DMUSIC] Sync with Wine Staging 3.3. CORE-14434 --- dll/directx/wine/dmusic/CMakeLists.txt | 4 +-- dll/directx/wine/dmusic/buffer.c | 4 ++- dll/directx/wine/dmusic/clock.c | 2 ++ dll/directx/wine/dmusic/collection.c | 4 +-- dll/directx/wine/dmusic/dmobject.c | 8 +++++- dll/directx/wine/dmusic/dmusic.c | 5 ++-- dll/directx/wine/dmusic/dmusic_main.c | 22 ++++++++++++++-- dll/directx/wine/dmusic/dmusic_private.h | 32 +++++++++++------------- dll/directx/wine/dmusic/download.c | 2 ++ dll/directx/wine/dmusic/instrument.c | 2 ++ dll/directx/wine/dmusic/port.c | 3 ++- dll/directx/wine/dmusic/precomp.h | 14 +++++++++++ dll/directx/wine/dmusic/version.rc | 2 +- media/doc/README.WINE | 2 +- 14 files changed, 75 insertions(+), 31 deletions(-) create mode 100644 dll/directx/wine/dmusic/precomp.h diff --git a/dll/directx/wine/dmusic/CMakeLists.txt b/dll/directx/wine/dmusic/CMakeLists.txt index fbb71ded91d..fe4c2706806 100644 --- a/dll/directx/wine/dmusic/CMakeLists.txt +++ b/dll/directx/wine/dmusic/CMakeLists.txt @@ -13,7 +13,7 @@ list(APPEND SOURCE download.c instrument.c port.c - dmusic_private.h) + precomp.h) add_library(dmusic SHARED ${SOURCE} @@ -23,5 +23,5 @@ add_library(dmusic SHARED set_module_type(dmusic win32dll) target_link_libraries(dmusic dxguid uuid wine) add_importlibs(dmusic ole32 advapi32 winmm dsound user32 msvcrt kernel32 ntdll) -add_pch(dmusic dmusic_private.h SOURCE) +add_pch(dmusic precomp.h SOURCE) add_cd_file(TARGET dmusic DESTINATION reactos/system32 FOR all) diff --git a/dll/directx/wine/dmusic/buffer.c b/dll/directx/wine/dmusic/buffer.c index 404200c46f7..9b0ca848a6f 100644 --- a/dll/directx/wine/dmusic/buffer.c +++ b/dll/directx/wine/dmusic/buffer.c @@ -20,8 +20,10 @@ */ #include "dmusic_private.h" +#include "initguid.h" +#include "dmksctrl.h" -#include +WINE_DEFAULT_DEBUG_CHANNEL(dmusic); static inline IDirectMusicBufferImpl *impl_from_IDirectMusicBuffer(IDirectMusicBuffer *iface) { diff --git a/dll/directx/wine/dmusic/clock.c b/dll/directx/wine/dmusic/clock.c index 58f93528750..2086bfa3f1e 100644 --- a/dll/directx/wine/dmusic/clock.c +++ b/dll/directx/wine/dmusic/clock.c @@ -20,6 +20,8 @@ #include "dmusic_private.h" +WINE_DEFAULT_DEBUG_CHANNEL(dmusic); + static inline IReferenceClockImpl *impl_from_IReferenceClock(IReferenceClock *iface) { return CONTAINING_RECORD(iface, IReferenceClockImpl, IReferenceClock_iface); diff --git a/dll/directx/wine/dmusic/collection.c b/dll/directx/wine/dmusic/collection.c index e2c53a86c5a..ec9914faa14 100644 --- a/dll/directx/wine/dmusic/collection.c +++ b/dll/directx/wine/dmusic/collection.c @@ -19,9 +19,9 @@ */ #include "dmusic_private.h" +#include "dmobject.h" -#include - +WINE_DEFAULT_DEBUG_CHANNEL(dmusic); WINE_DECLARE_DEBUG_CHANNEL(dmfile); /***************************************************************************** diff --git a/dll/directx/wine/dmusic/dmobject.c b/dll/directx/wine/dmusic/dmobject.c index 8f0441b7d66..cabb6f74db9 100644 --- a/dll/directx/wine/dmusic/dmobject.c +++ b/dll/directx/wine/dmusic/dmobject.c @@ -20,7 +20,13 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "dmusic_private.h" +#define COBJMACROS +#include "objbase.h" +#include "dmusici.h" +#include "dmobject.h" +#include "wine/debug.h" + +WINE_DEFAULT_DEBUG_CHANNEL(dmobj); /* Generic IDirectMusicObject methods */ static inline struct dmobject *impl_from_IDirectMusicObject(IDirectMusicObject *iface) diff --git a/dll/directx/wine/dmusic/dmusic.c b/dll/directx/wine/dmusic/dmusic.c index bfc13b893b2..58dcd9d9524 100644 --- a/dll/directx/wine/dmusic/dmusic.c +++ b/dll/directx/wine/dmusic/dmusic.c @@ -19,10 +19,11 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#include + #include "dmusic_private.h" -#include -#include +WINE_DEFAULT_DEBUG_CHANNEL(dmusic); static inline IDirectMusic8Impl *impl_from_IDirectMusic8(IDirectMusic8 *iface) { diff --git a/dll/directx/wine/dmusic/dmusic_main.c b/dll/directx/wine/dmusic/dmusic_main.c index 3aae6168dd0..da6f45869da 100644 --- a/dll/directx/wine/dmusic/dmusic_main.c +++ b/dll/directx/wine/dmusic/dmusic_main.c @@ -17,10 +17,28 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ -#include "dmusic_private.h" +#include "config.h" +#include "wine/port.h" #include -#include +#include + +#define COBJMACROS + +#include "windef.h" +#include "winbase.h" +#include "winnt.h" +#include "wingdi.h" +#include "winuser.h" +#include "winreg.h" +#include "objbase.h" +#include "rpcproxy.h" +#include "initguid.h" +#include "dmusici.h" + +#include "dmusic_private.h" + +WINE_DEFAULT_DEBUG_CHANNEL(dmusic); static HINSTANCE instance; LONG DMUSIC_refCount = 0; diff --git a/dll/directx/wine/dmusic/dmusic_private.h b/dll/directx/wine/dmusic/dmusic_private.h index 2ba5e7462ec..f9839edfdae 100644 --- a/dll/directx/wine/dmusic/dmusic_private.h +++ b/dll/directx/wine/dmusic/dmusic_private.h @@ -22,32 +22,28 @@ #ifndef __WINE_DMUSIC_PRIVATE_H #define __WINE_DMUSIC_PRIVATE_H -#include - #include -#define WIN32_NO_STATUS -#define _INC_WINDOWS -#define COM_NO_WINDOWS_H - #define COBJMACROS #define NONAMELESSUNION #define NONAMELESSSTRUCT -#include -#include -#include -#include -#include -#include +#include "windef.h" +#include "winbase.h" +#include "winnt.h" +#include "wingdi.h" +#include "winuser.h" -#include -#include -#include +#include "wine/debug.h" +#include "wine/list.h" +#include "wine/unicode.h" +#include "winreg.h" +#include "objbase.h" -#include "dmobject.h" - -WINE_DEFAULT_DEBUG_CHANNEL(dmusic); +#include "dmusici.h" +#include "dmusicf.h" +#include "dmusics.h" +#include "dmksctrl.h" /***************************************************************************** * Interfaces diff --git a/dll/directx/wine/dmusic/download.c b/dll/directx/wine/dmusic/download.c index cc18c20123e..a88ec2c584c 100644 --- a/dll/directx/wine/dmusic/download.c +++ b/dll/directx/wine/dmusic/download.c @@ -20,6 +20,8 @@ #include "dmusic_private.h" +WINE_DEFAULT_DEBUG_CHANNEL(dmusic); + static inline IDirectMusicDownloadImpl* impl_from_IDirectMusicDownload(IDirectMusicDownload *iface) { return CONTAINING_RECORD(iface, IDirectMusicDownloadImpl, IDirectMusicDownload_iface); diff --git a/dll/directx/wine/dmusic/instrument.c b/dll/directx/wine/dmusic/instrument.c index 2a341890131..87b31c1ed6c 100644 --- a/dll/directx/wine/dmusic/instrument.c +++ b/dll/directx/wine/dmusic/instrument.c @@ -20,6 +20,8 @@ #include "dmusic_private.h" +WINE_DEFAULT_DEBUG_CHANNEL(dmusic); + static const GUID IID_IDirectMusicInstrumentPRIVATE = { 0xbcb20080, 0xa40c, 0x11d1, { 0x86, 0xbc, 0x00, 0xc0, 0x4f, 0xbf, 0x8f, 0xef } }; /* IDirectMusicInstrument IUnknown part: */ diff --git a/dll/directx/wine/dmusic/port.c b/dll/directx/wine/dmusic/port.c index af5eafbf45c..50646153a70 100644 --- a/dll/directx/wine/dmusic/port.c +++ b/dll/directx/wine/dmusic/port.c @@ -19,9 +19,10 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#include #include "dmusic_private.h" -#include +WINE_DEFAULT_DEBUG_CHANNEL(dmusic); typedef struct SynthPortImpl { IDirectMusicPort IDirectMusicPort_iface; diff --git a/dll/directx/wine/dmusic/precomp.h b/dll/directx/wine/dmusic/precomp.h new file mode 100644 index 00000000000..acdbe9a0abc --- /dev/null +++ b/dll/directx/wine/dmusic/precomp.h @@ -0,0 +1,14 @@ + +#ifndef __WINE_DMUSIC_PRECOMP_H +#define __WINE_DMUSIC_PRECOMP_H + +#include + +#define WIN32_NO_STATUS +#define _INC_WINDOWS +#define COM_NO_WINDOWS_H + +#include "dmusic_private.h" +#include "dmobject.h" + +#endif /* !__WINE_DMUSIC_PRECOMP_H */ diff --git a/dll/directx/wine/dmusic/version.rc b/dll/directx/wine/dmusic/version.rc index f7cd58750c4..89292ecde6d 100644 --- a/dll/directx/wine/dmusic/version.rc +++ b/dll/directx/wine/dmusic/version.rc @@ -26,4 +26,4 @@ #define WINE_PRODUCTVERSION_STR "5.3.1.904" #define WINE_EXTRAVALUES VALUE "OLESelfRegister","" -#include +#include "wine/wine_common_ver.rc" diff --git a/media/doc/README.WINE b/media/doc/README.WINE index 0c6dba68ad9..352808564a5 100644 --- a/media/doc/README.WINE +++ b/media/doc/README.WINE @@ -32,7 +32,7 @@ reactos/dll/directx/wine/ddraw # Synced to WineStaging-3.3 reactos/dll/directx/wine/devenum # Synced to WineStaging-3.3 reactos/dll/directx/wine/dinput # Synced to WineStaging-3.3 reactos/dll/directx/wine/dinput8 # Synced to WineStaging-3.3 -reactos/dll/directx/wine/dmusic # Synced to WineStaging-2.9 +reactos/dll/directx/wine/dmusic # Synced to WineStaging-3.3 reactos/dll/directx/wine/dplay # Synced to WineStaging-2.9 reactos/dll/directx/wine/dplayx # Synced to WineStaging-2.16 reactos/dll/directx/wine/dsound # Synced to Wine-1.3.29