Fixed profile cache flushing when no filename is specified (reported
[wine/multimedia.git] / dlls / shdocvw / persist.c
blobc07a914aed02954c0ec45151de411611c93fefa4
1 /*
2 * Implementation of IPersist interfaces for IE Web Browser control
4 * Copyright 2001 John R. Sheets (for CodeWeavers)
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2.1 of the License, or (at your option) any later version.
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Lesser General Public License for more details.
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with this library; if not, write to the Free Software
18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
21 #include "wine/debug.h"
22 #include "shdocvw.h"
24 WINE_DEFAULT_DEBUG_CHANNEL(shdocvw);
26 /**********************************************************************
27 * Implement the IPersistStorage interface
30 static HRESULT WINAPI WBPS_QueryInterface(LPPERSISTSTORAGE iface,
31 REFIID riid, LPVOID *ppobj)
33 FIXME("- no interface\n\tIID:\t%s\n", debugstr_guid(riid));
35 if (ppobj == NULL) return E_POINTER;
37 return E_NOINTERFACE;
40 static ULONG WINAPI WBPS_AddRef(LPPERSISTSTORAGE iface)
42 SHDOCVW_LockModule();
44 return 2; /* non-heap based object */
47 static ULONG WINAPI WBPS_Release(LPPERSISTSTORAGE iface)
49 SHDOCVW_UnlockModule();
51 return 1; /* non-heap based object */
54 static HRESULT WINAPI WBPS_GetClassID(LPPERSISTSTORAGE iface, CLSID *pClassID)
56 FIXME("stub: CLSID = %s\n", debugstr_guid(pClassID));
57 return S_OK;
60 static HRESULT WINAPI WBPS_IsDirty(LPPERSISTSTORAGE iface)
62 FIXME("stub\n");
63 return S_OK;
66 static HRESULT WINAPI WBPS_InitNew(LPPERSISTSTORAGE iface, LPSTORAGE pStg)
68 FIXME("stub: LPSTORAGE = %p\n", pStg);
69 return S_OK;
72 static HRESULT WINAPI WBPS_Load(LPPERSISTSTORAGE iface, LPSTORAGE pStg)
74 FIXME("stub: LPSTORAGE = %p\n", pStg);
75 return S_OK;
78 static HRESULT WINAPI WBPS_Save(LPPERSISTSTORAGE iface, LPSTORAGE pStg,
79 BOOL fSameAsLoad)
81 FIXME("stub: LPSTORAGE = %p, fSameAsLoad = %d\n", pStg, fSameAsLoad);
82 return S_OK;
85 static HRESULT WINAPI WBPS_SaveCompleted(LPPERSISTSTORAGE iface, LPSTORAGE pStgNew)
87 FIXME("stub: LPSTORAGE = %p\n", pStgNew);
88 return S_OK;
91 /**********************************************************************
92 * IPersistStorage virtual function table for IE Web Browser component
95 static IPersistStorageVtbl WBPS_Vtbl =
97 WBPS_QueryInterface,
98 WBPS_AddRef,
99 WBPS_Release,
100 WBPS_GetClassID,
101 WBPS_IsDirty,
102 WBPS_InitNew,
103 WBPS_Load,
104 WBPS_Save,
105 WBPS_SaveCompleted
108 IPersistStorageImpl SHDOCVW_PersistStorage = {&WBPS_Vtbl};
111 /**********************************************************************
112 * Implement the IPersistStreamInit interface
115 static HRESULT WINAPI WBPSI_QueryInterface(LPPERSISTSTREAMINIT iface,
116 REFIID riid, LPVOID *ppobj)
118 FIXME("- no interface\n\tIID:\t%s\n", debugstr_guid(riid));
120 if (ppobj == NULL) return E_POINTER;
122 return E_NOINTERFACE;
125 static ULONG WINAPI WBPSI_AddRef(LPPERSISTSTREAMINIT iface)
127 SHDOCVW_LockModule();
129 return 2; /* non-heap based object */
132 static ULONG WINAPI WBPSI_Release(LPPERSISTSTREAMINIT iface)
134 SHDOCVW_UnlockModule();
136 return 1; /* non-heap based object */
139 static HRESULT WINAPI WBPSI_GetClassID(LPPERSISTSTREAMINIT iface, CLSID *pClassID)
141 FIXME("stub: CLSID = %s\n", debugstr_guid(pClassID));
142 return S_OK;
145 static HRESULT WINAPI WBPSI_IsDirty(LPPERSISTSTREAMINIT iface)
147 FIXME("stub\n");
148 return S_OK;
151 static HRESULT WINAPI WBPSI_Load(LPPERSISTSTREAMINIT iface, LPSTREAM pStg)
153 FIXME("stub: LPSTORAGE = %p\n", pStg);
154 return S_OK;
157 static HRESULT WINAPI WBPSI_Save(LPPERSISTSTREAMINIT iface, LPSTREAM pStg,
158 BOOL fSameAsLoad)
160 FIXME("stub: LPSTORAGE = %p, fSameAsLoad = %d\n", pStg, fSameAsLoad);
161 return S_OK;
164 static HRESULT WINAPI WBPSI_GetSizeMax(LPPERSISTSTREAMINIT iface,
165 ULARGE_INTEGER *pcbSize)
167 FIXME("stub: ULARGE_INTEGER = %p\n", pcbSize);
168 return S_OK;
171 static HRESULT WINAPI WBPSI_InitNew(LPPERSISTSTREAMINIT iface)
173 FIXME("stub\n");
174 return S_OK;
177 /**********************************************************************
178 * IPersistStreamInit virtual function table for IE Web Browser component
181 static IPersistStreamInitVtbl WBPSI_Vtbl =
183 WBPSI_QueryInterface,
184 WBPSI_AddRef,
185 WBPSI_Release,
186 WBPSI_GetClassID,
187 WBPSI_IsDirty,
188 WBPSI_Load,
189 WBPSI_Save,
190 WBPSI_GetSizeMax,
191 WBPSI_InitNew
194 IPersistStreamInitImpl SHDOCVW_PersistStreamInit = {&WBPSI_Vtbl};