dmstyle: Add GUID_IDirectMusicStyle support in Style Track GetParam.

Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Signed-off-by: Michael Stefaniuc <mstefani@winehq.org>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Alistair Leslie-Hughes 2019-11-18 03:07:53 +00:00 committed by Alexandre Julliard
parent bcab0696e0
commit de11d172dc

View file

@ -132,15 +132,31 @@ static HRESULT WINAPI style_track_Play(IDirectMusicTrack8 *iface, void *pStateDa
return S_OK;
}
static HRESULT WINAPI style_track_GetParam(IDirectMusicTrack8 *iface, REFGUID rguidType,
MUSIC_TIME mtTime, MUSIC_TIME *pmtNext, void *pParam)
static HRESULT WINAPI style_track_GetParam(IDirectMusicTrack8 *iface, REFGUID type,
MUSIC_TIME time, MUSIC_TIME *next, void *param)
{
IDirectMusicStyleTrack *This = impl_from_IDirectMusicTrack8(iface);
FIXME("(%p, %s, %d, %p, %p): stub\n", This, debugstr_dmguid(rguidType), mtTime, pmtNext, pParam);
struct list *item = NULL;
if (!rguidType)
FIXME("(%p, %s, %d, %p, %p): stub\n", This, debugstr_dmguid(type), time, next, param);
if (!type)
return E_POINTER;
if (IsEqualGUID(&GUID_IDirectMusicStyle, type)) {
LIST_FOR_EACH (item, &This->Items) {
DMUS_PRIVATE_STYLE_ITEM *style = LIST_ENTRY(item, DMUS_PRIVATE_STYLE_ITEM, entry);
if (style->pObject) {
IDirectMusicStyle8_AddRef(style->pObject);
*((IDirectMusicStyle8**)param) = style->pObject;
return S_OK;
}
}
return DMUS_E_NOT_FOUND;
}
return S_OK;
}