wined3d: Pass a wined3d_device_context to wined3d_texture_blt().
[wine/zf.git] / dlls / wmvcore / wmvcore_main.c
blob7d030a0e93a38a9778204eca5a6bb8a535c9e4a0
1 /*
2 * Copyright 2012 Austin English
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
19 #include "wmvcore.h"
21 #include "initguid.h"
22 #include "wmsdk.h"
23 #include "wine/debug.h"
24 #include "wine/heap.h"
26 WINE_DEFAULT_DEBUG_CHANNEL(wmvcore);
28 HRESULT WINAPI DllRegisterServer(void)
30 FIXME("(): stub\n");
32 return S_OK;
35 HRESULT WINAPI WMCheckURLExtension(const WCHAR *url)
37 FIXME("(%s): stub\n", wine_dbgstr_w(url));
39 if (!url)
40 return E_INVALIDARG;
42 return NS_E_INVALID_NAME;
45 HRESULT WINAPI WMCheckURLScheme(const WCHAR *scheme)
47 FIXME("(%s): stub\n", wine_dbgstr_w(scheme));
49 return NS_E_INVALID_NAME;
52 HRESULT WINAPI WMCreateEditor(IWMMetadataEditor **editor)
54 FIXME("(%p): stub\n", editor);
56 *editor = NULL;
58 return E_NOTIMPL;
61 HRESULT WINAPI WMCreateBackupRestorer(IUnknown *callback, IWMLicenseBackup **licBackup)
63 FIXME("(%p %p): stub\n", callback, licBackup);
65 if (!callback)
66 return E_INVALIDARG;
68 *licBackup = NULL;
70 return E_NOTIMPL;
73 HRESULT WINAPI WMIsContentProtected(const WCHAR *filename, BOOL *protected)
75 FIXME("(%s %p): semi-stub\n", wine_dbgstr_w(filename), protected);
77 if (!filename || !protected)
78 return E_INVALIDARG;
80 *protected = FALSE;
82 return S_FALSE;
85 typedef struct {
86 IWMProfileManager2 IWMProfileManager2_iface;
87 LONG ref;
88 } WMProfileManager;
90 static inline WMProfileManager *impl_from_IWMProfileManager2(IWMProfileManager2 *iface)
92 return CONTAINING_RECORD(iface, WMProfileManager, IWMProfileManager2_iface);
95 static HRESULT WINAPI WMProfileManager_QueryInterface(IWMProfileManager2 *iface, REFIID riid, void **ppv)
97 WMProfileManager *This = impl_from_IWMProfileManager2(iface);
99 if(IsEqualGUID(&IID_IUnknown, riid)) {
100 TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv);
101 *ppv = &This->IWMProfileManager2_iface;
102 }else if(IsEqualGUID(&IID_IWMProfileManager, riid)) {
103 TRACE("(%p)->(IID_IWMProfileManager %p)\n", This, ppv);
104 *ppv = &This->IWMProfileManager2_iface;
105 }else if(IsEqualGUID(&IID_IWMProfileManager2, riid)) {
106 TRACE("(%p)->(IID_IWMProfileManager2 %p)\n", This, ppv);
107 *ppv = &This->IWMProfileManager2_iface;
108 }else {
109 FIXME("Unsupported iface %s\n", debugstr_guid(riid));
110 *ppv = NULL;
111 return E_NOINTERFACE;
114 IUnknown_AddRef((IUnknown*)*ppv);
115 return S_OK;
118 static ULONG WINAPI WMProfileManager_AddRef(IWMProfileManager2 *iface)
120 WMProfileManager *This = impl_from_IWMProfileManager2(iface);
121 LONG ref = InterlockedIncrement(&This->ref);
123 TRACE("(%p) ref=%d\n", This, ref);
125 return ref;
128 static ULONG WINAPI WMProfileManager_Release(IWMProfileManager2 *iface)
130 WMProfileManager *This = impl_from_IWMProfileManager2(iface);
131 LONG ref = InterlockedDecrement(&This->ref);
133 TRACE("(%p) ref=%d\n", This, ref);
135 if(!ref)
136 heap_free(This);
138 return ref;
141 static HRESULT WINAPI WMProfileManager_CreateEmptyProfile(IWMProfileManager2 *iface, WMT_VERSION version, IWMProfile **ret)
143 WMProfileManager *This = impl_from_IWMProfileManager2(iface);
144 FIXME("(%p)->(%x %p)\n", This, version, ret);
145 return E_NOTIMPL;
148 static HRESULT WINAPI WMProfileManager_LoadProfileByID(IWMProfileManager2 *iface, REFGUID guid, IWMProfile **ret)
150 WMProfileManager *This = impl_from_IWMProfileManager2(iface);
151 FIXME("(%p)->(%s %p)\n", This, debugstr_guid(guid), ret);
152 return E_NOTIMPL;
155 static HRESULT WINAPI WMProfileManager_LoadProfileByData(IWMProfileManager2 *iface, const WCHAR *profile, IWMProfile **ret)
157 WMProfileManager *This = impl_from_IWMProfileManager2(iface);
158 FIXME("(%p)->(%s %p)\n", This, debugstr_w(profile), ret);
159 return E_NOTIMPL;
162 static HRESULT WINAPI WMProfileManager_SaveProfile(IWMProfileManager2 *iface, IWMProfile *profile, WCHAR *profile_str, DWORD *len)
164 WMProfileManager *This = impl_from_IWMProfileManager2(iface);
165 FIXME("(%p)->(%p %p %p)\n", This, profile, profile_str, len);
166 return E_NOTIMPL;
169 static HRESULT WINAPI WMProfileManager_GetSystemProfileCount(IWMProfileManager2 *iface, DWORD *ret)
171 WMProfileManager *This = impl_from_IWMProfileManager2(iface);
172 FIXME("(%p)->(%p)\n", This, ret);
173 return E_NOTIMPL;
176 static HRESULT WINAPI WMProfileManager_LoadSystemProfile(IWMProfileManager2 *iface, DWORD index, IWMProfile **ret)
178 WMProfileManager *This = impl_from_IWMProfileManager2(iface);
179 FIXME("(%p)->(%d %p)\n", This, index, ret);
180 return E_NOTIMPL;
183 static HRESULT WINAPI WMProfileManager2_GetSystemProfileVersion(IWMProfileManager2 *iface, WMT_VERSION *version)
185 WMProfileManager *This = impl_from_IWMProfileManager2(iface);
186 FIXME("(%p)->(%p)\n", This, version);
187 return E_NOTIMPL;
190 static HRESULT WINAPI WMProfileManager2_SetSystemProfileVersion(IWMProfileManager2 *iface, WMT_VERSION version)
192 WMProfileManager *This = impl_from_IWMProfileManager2(iface);
193 FIXME("(%p)->(%x)\n", This, version);
194 return E_NOTIMPL;
197 static const IWMProfileManager2Vtbl WMProfileManager2Vtbl = {
198 WMProfileManager_QueryInterface,
199 WMProfileManager_AddRef,
200 WMProfileManager_Release,
201 WMProfileManager_CreateEmptyProfile,
202 WMProfileManager_LoadProfileByID,
203 WMProfileManager_LoadProfileByData,
204 WMProfileManager_SaveProfile,
205 WMProfileManager_GetSystemProfileCount,
206 WMProfileManager_LoadSystemProfile,
207 WMProfileManager2_GetSystemProfileVersion,
208 WMProfileManager2_SetSystemProfileVersion
211 HRESULT WINAPI WMCreateProfileManager(IWMProfileManager **ret)
213 WMProfileManager *profile_mgr;
215 TRACE("(%p)\n", ret);
217 profile_mgr = heap_alloc(sizeof(*profile_mgr));
218 if(!profile_mgr)
219 return E_OUTOFMEMORY;
221 profile_mgr->IWMProfileManager2_iface.lpVtbl = &WMProfileManager2Vtbl;
222 profile_mgr->ref = 1;
224 *ret = (IWMProfileManager *)&profile_mgr->IWMProfileManager2_iface;
225 return S_OK;