Removed some uses of the non-standard ICOM_THIS macro.
[wine/multimedia.git] / dlls / dmusic / portdownload.c
blob0c47b06855b98f4620ddb7b15b957517ba42e727
1 /* IDirectMusicPortDownloadImpl Implementation
3 * Copyright (C) 2003-2004 Rok Mandeljc
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU Library General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
20 #include "dmusic_private.h"
22 WINE_DEFAULT_DEBUG_CHANNEL(dmusic);
24 /* IDirectMusicPortDownload IUnknown parts follow: */
25 HRESULT WINAPI IDirectMusicPortDownloadImpl_QueryInterface (LPDIRECTMUSICPORTDOWNLOAD iface, REFIID riid, LPVOID *ppobj) {
26 IDirectMusicPortDownloadImpl *This = (IDirectMusicPortDownloadImpl *)iface;
27 TRACE("(%p, %s, %p)\n", This, debugstr_dmguid(riid), ppobj);
29 if (IsEqualIID (riid, &IID_IUnknown) || IsEqualGUID(riid, &IID_IDirectMusicPortDownload)) {
30 IDirectMusicPortDownloadImpl_AddRef(iface);
31 *ppobj = This;
32 return S_OK;
34 WARN("(%p, %s, %p): not found\n", This, debugstr_dmguid(riid), ppobj);
35 return E_NOINTERFACE;
38 ULONG WINAPI IDirectMusicPortDownloadImpl_AddRef (LPDIRECTMUSICPORTDOWNLOAD iface) {
39 IDirectMusicPortDownloadImpl *This = (IDirectMusicPortDownloadImpl *)iface;
40 TRACE("(%p): AddRef from %ld\n", This, This->ref);
41 return ++(This->ref);
44 ULONG WINAPI IDirectMusicPortDownloadImpl_Release (LPDIRECTMUSICPORTDOWNLOAD iface) {
45 IDirectMusicPortDownloadImpl *This = (IDirectMusicPortDownloadImpl *)iface;
46 ULONG ref = --This->ref;
47 TRACE("(%p): ReleaseRef to %ld\n", This, This->ref);
48 if (ref == 0) {
49 HeapFree(GetProcessHeap(), 0, This);
51 return ref;
54 /* IDirectMusicPortDownload Interface follow: */
55 HRESULT WINAPI IDirectMusicPortDownloadImpl_GetBuffer (LPDIRECTMUSICPORTDOWNLOAD iface, DWORD dwDLId, IDirectMusicDownload** ppIDMDownload) {
56 IDirectMusicPortDownloadImpl *This = (IDirectMusicPortDownloadImpl *)iface;
57 FIXME("(%p, %ld, %p): stub\n", This, dwDLId, ppIDMDownload);
58 return S_OK;
61 HRESULT WINAPI IDirectMusicPortDownloadImpl_AllocateBuffer (LPDIRECTMUSICPORTDOWNLOAD iface, DWORD dwSize, IDirectMusicDownload** ppIDMDownload) {
62 IDirectMusicPortDownloadImpl *This = (IDirectMusicPortDownloadImpl *)iface;
63 FIXME("(%p, %ld, %p): stub\n", This, dwSize, ppIDMDownload);
64 return S_OK;
67 HRESULT WINAPI IDirectMusicPortDownloadImpl_GetDLId (LPDIRECTMUSICPORTDOWNLOAD iface, DWORD* pdwStartDLId, DWORD dwCount) {
68 IDirectMusicPortDownloadImpl *This = (IDirectMusicPortDownloadImpl *)iface;
69 FIXME("(%p, %p, %ld): stub\n", This, pdwStartDLId, dwCount);
70 return S_OK;
73 HRESULT WINAPI IDirectMusicPortDownloadImpl_GetAppend (LPDIRECTMUSICPORTDOWNLOAD iface, DWORD* pdwAppend) {
74 IDirectMusicPortDownloadImpl *This = (IDirectMusicPortDownloadImpl *)iface;
75 FIXME("(%p, %p): stub\n", This, pdwAppend);
76 return S_OK;
79 HRESULT WINAPI IDirectMusicPortDownloadImpl_Download (LPDIRECTMUSICPORTDOWNLOAD iface, IDirectMusicDownload* pIDMDownload) {
80 IDirectMusicPortDownloadImpl *This = (IDirectMusicPortDownloadImpl *)iface;
81 FIXME("(%p, %p): stub\n", This, pIDMDownload);
82 return S_OK;
85 HRESULT WINAPI IDirectMusicPortDownloadImpl_Unload (LPDIRECTMUSICPORTDOWNLOAD iface, IDirectMusicDownload* pIDMDownload) {
86 IDirectMusicPortDownloadImpl *This = (IDirectMusicPortDownloadImpl *)iface;
87 FIXME("(%p, %p): stub\n", This, pIDMDownload);
88 return S_OK;
91 IDirectMusicPortDownloadVtbl DirectMusicPortDownload_Vtbl = {
92 IDirectMusicPortDownloadImpl_QueryInterface,
93 IDirectMusicPortDownloadImpl_AddRef,
94 IDirectMusicPortDownloadImpl_Release,
95 IDirectMusicPortDownloadImpl_GetBuffer,
96 IDirectMusicPortDownloadImpl_AllocateBuffer,
97 IDirectMusicPortDownloadImpl_GetDLId,
98 IDirectMusicPortDownloadImpl_GetAppend,
99 IDirectMusicPortDownloadImpl_Download,
100 IDirectMusicPortDownloadImpl_Unload