~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~ [ freetext search ] ~ [ file search ] ~

Wine Cross Reference
wine/dlls/wuapi/updates.c

Version: ~ [ wine-1.5.31 ] ~ [ wine-1.5.30 ] ~ [ wine-1.5.29 ] ~ [ wine-1.5.28 ] ~ [ wine-1.5.27 ] ~ [ wine-1.5.26 ] ~ [ wine-1.5.25 ] ~ [ wine-1.5.24 ] ~ [ wine-1.5.23 ] ~ [ wine-1.5.22 ] ~ [ wine-1.5.21 ] ~ [ wine-1.5.20 ] ~ [ wine-1.5.19 ] ~ [ wine-1.5.18 ] ~ [ wine-1.5.17 ] ~ [ wine-1.5.16 ] ~ [ wine-1.5.15 ] ~ [ wine-1.5.14 ] ~ [ wine-1.5.13 ] ~ [ wine-1.5.12 ] ~ [ wine-1.5.11 ] ~ [ wine-1.5.10 ] ~ [ wine-1.5.9 ] ~ [ wine-1.5.8 ] ~ [ wine-1.5.7 ] ~ [ wine-1.4.1 ] ~ [ wine-1.5.6 ] ~ [ wine-1.5.5 ] ~ [ wine-1.5.4 ] ~ [ wine-1.5.3 ] ~ [ wine-1.5.2 ] ~ [ wine-1.5.1 ] ~ [ wine-1.5.0 ] ~ [ wine-1.4 ] ~ [ wine-1.4-rc6 ] ~ [ wine-1.4-rc5 ] ~ [ wine-1.4-rc4 ] ~ [ wine-1.4-rc3 ] ~ [ wine-1.4-rc2 ] ~ [ wine-1.4-rc1 ] ~ [ wine-1.3.37 ] ~ [ wine-1.3.36 ] ~ [ wine-1.3.35 ] ~ [ wine-1.3.34 ] ~ [ wine-1.3.33 ] ~ [ wine-1.3.32 ] ~ [ wine-1.3.31 ] ~ [ wine-1.3.30 ] ~ [ wine-1.3.29 ] ~ [ wine-1.3.28 ] ~ [ wine-1.3.27 ] ~ [ wine-1.3.26 ] ~ [ wine-1.3.25 ] ~ [ wine-1.3.24 ] ~ [ wine-1.3.23 ] ~ [ wine-1.3.22 ] ~ [ wine-1.3.21 ] ~ [ wine-1.3.20 ] ~ [ wine-1.3.19 ] ~ [ wine-1.3.18 ] ~ [ wine-1.2.3 ] ~ [ wine-1.3.17 ] ~ [ wine-1.3.16 ] ~ [ wine-1.3.15 ] ~ [ wine-1.3.14 ] ~ [ wine-1.3.13 ] ~ [ wine-1.3.12 ] ~ [ wine-1.3.11 ] ~ [ wine-1.3.10 ] ~ [ wine-1.3.9 ] ~ [ wine-1.2.2 ] ~ [ wine-1.3.8 ] ~ [ wine-1.3.7 ] ~ [ wine-1.3.6 ] ~ [ wine-1.3.5 ] ~ [ wine-1.2.1 ] ~ [ wine-1.3.4 ] ~ [ wine-1.3.3 ] ~ [ wine-1.3.2 ] ~ [ wine-1.3.1 ] ~ [ wine-1.3.0 ] ~ [ wine-1.2 ] ~ [ wine-1.2-rc7 ] ~ [ wine-1.2-rc6 ] ~ [ wine-1.2-rc5 ] ~ [ wine-1.2-rc4 ] ~ [ wine-1.2-rc3 ] ~ [ wine-1.2-rc2 ] ~ [ wine-1.2-rc1 ] ~ [ wine-1.1.44 ] ~ [ wine-1.1.43 ] ~ [ wine-1.1.42 ] ~ [ wine-1.1.41 ] ~ [ wine-1.1.40 ] ~ [ wine-1.1.39 ] ~ [ wine-1.1.38 ] ~ [ wine-1.1.37 ] ~ [ wine-1.1.36 ] ~ [ wine-1.1.35 ] ~ [ wine-1.1.34 ] ~ [ wine-1.1.33 ] ~ [ wine-1.1.32 ] ~ [ wine-1.1.31 ] ~ [ wine-1.1.30 ] ~ [ wine-1.1.29 ] ~ [ wine-1.1.28 ] ~ [ wine-1.1.27 ] ~ [ wine-1.1.26 ] ~ [ wine-1.1.25 ] ~ [ wine-1.1.24 ] ~ [ wine-1.1.23 ] ~ [ wine-1.1.22 ] ~ [ wine-1.1.21 ] ~ [ wine-1.1.20 ] ~ [ wine-1.1.19 ] ~ [ wine-1.1.18 ] ~ [ wine-1.1.17 ] ~ [ wine-1.1.16 ] ~ [ wine-1.1.15 ] ~ [ wine-1.1.14 ] ~ [ wine-1.1.13 ] ~ [ wine-1.1.12 ] ~ [ wine-1.1.11 ] ~ [ wine-1.1.10 ] ~ [ wine-1.1.9 ] ~ [ wine-1.1.8 ] ~ [ wine-1.1.7 ] ~ [ wine-1.0.1 ] ~ [ wine-1.1.6 ] ~ [ wine-1.1.5 ] ~ [ wine-1.1.4 ] ~ [ wine-1.1.3 ] ~ [ wine-1.1.2 ] ~ [ wine-1.1.1 ] ~ [ wine-1.1.0 ] ~ [ wine-1.0 ] ~

  1 /*
  2  * IAutomaticUpdates implementation
  3  *
  4  * Copyright 2008 Hans Leidekker
  5  *
  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.
 10  *
 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.
 15  *
 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
 19  */
 20 
 21 #define COBJMACROS
 22 
 23 #include "config.h"
 24 #include <stdarg.h>
 25 
 26 #include "windef.h"
 27 #include "winbase.h"
 28 #include "winuser.h"
 29 #include "ole2.h"
 30 #include "wuapi.h"
 31 
 32 #include "wine/debug.h"
 33 
 34 WINE_DEFAULT_DEBUG_CHANNEL(wuapi);
 35 
 36 typedef struct _automatic_updates
 37 {
 38     const struct IAutomaticUpdatesVtbl *vtbl;
 39     LONG refs;
 40 } automatic_updates;
 41 
 42 static inline automatic_updates *impl_from_IAutomaticUpdates( IAutomaticUpdates *iface )
 43 {
 44     return (automatic_updates *)((char*)iface - FIELD_OFFSET( automatic_updates, vtbl ));
 45 }
 46 
 47 static ULONG WINAPI automatic_updates_AddRef(
 48     IAutomaticUpdates *iface )
 49 {
 50     automatic_updates *automatic_updates = impl_from_IAutomaticUpdates( iface );
 51     return InterlockedIncrement( &automatic_updates->refs );
 52 }
 53 
 54 static ULONG WINAPI automatic_updates_Release(
 55     IAutomaticUpdates *iface )
 56 {
 57     automatic_updates *automatic_updates = impl_from_IAutomaticUpdates( iface );
 58     LONG refs = InterlockedDecrement( &automatic_updates->refs );
 59     if (!refs)
 60     {
 61         TRACE("destroying %p\n", automatic_updates);
 62         HeapFree( GetProcessHeap(), 0, automatic_updates );
 63     }
 64     return refs;
 65 }
 66 
 67 static HRESULT WINAPI automatic_updates_QueryInterface(
 68     IAutomaticUpdates *iface,
 69     REFIID riid,
 70     void **ppvObject )
 71 {
 72     automatic_updates *This = impl_from_IAutomaticUpdates( iface );
 73 
 74     TRACE("%p %s %p\n", This, debugstr_guid( riid ), ppvObject );
 75 
 76     if ( IsEqualGUID( riid, &IID_IAutomaticUpdates ) ||
 77          IsEqualGUID( riid, &IID_IDispatch ) ||
 78          IsEqualGUID( riid, &IID_IUnknown ) )
 79     {
 80         *ppvObject = iface;
 81     }
 82     else
 83     {
 84         FIXME("interface %s not implemented\n", debugstr_guid(riid));
 85         return E_NOINTERFACE;
 86     }
 87     IAutomaticUpdates_AddRef( iface );
 88     return S_OK;
 89 }
 90 
 91 static HRESULT WINAPI automatic_updates_GetTypeInfoCount(
 92     IAutomaticUpdates *iface,
 93     UINT *pctinfo )
 94 {
 95     FIXME("\n");
 96     return E_NOTIMPL;
 97 }
 98 
 99 static HRESULT WINAPI automatic_updates_GetTypeInfo(
100     IAutomaticUpdates *iface,
101     UINT iTInfo,
102     LCID lcid,
103     ITypeInfo **ppTInfo )
104 {
105     FIXME("\n");
106     return E_NOTIMPL;
107 }
108 
109 static HRESULT WINAPI automatic_updates_GetIDsOfNames(
110     IAutomaticUpdates *iface,
111     REFIID riid,
112     LPOLESTR *rgszNames,
113     UINT cNames,
114     LCID lcid,
115     DISPID *rgDispId )
116 {
117     FIXME("\n");
118     return E_NOTIMPL;
119 }
120 
121 static HRESULT WINAPI automatic_updates_Invoke(
122     IAutomaticUpdates *iface,
123     DISPID dispIdMember,
124     REFIID riid,
125     LCID lcid,
126     WORD wFlags,
127     DISPPARAMS *pDispParams,
128     VARIANT *pVarResult,
129     EXCEPINFO *pExcepInfo,
130     UINT *puArgErr )
131 {
132     FIXME("\n");
133     return E_NOTIMPL;
134 }
135 
136 static HRESULT WINAPI automatic_updates_DetectNow(
137     IAutomaticUpdates *This )
138 {
139     FIXME("\n");
140     return E_NOTIMPL;
141 }
142 
143 static HRESULT WINAPI automatic_updates_Pause(
144     IAutomaticUpdates *This )
145 {
146     FIXME("\n");
147     return E_NOTIMPL;
148 }
149 
150 static HRESULT WINAPI automatic_updates_Resume(
151     IAutomaticUpdates *This )
152 {
153     FIXME("\n");
154     return E_NOTIMPL;
155 }
156 
157 static HRESULT WINAPI automatic_updates_ShowSettingsDialog(
158     IAutomaticUpdates *This )
159 {
160     FIXME("\n");
161     return E_NOTIMPL;
162 }
163 
164 static HRESULT WINAPI automatic_updates_EnableService(
165     IAutomaticUpdates *This )
166 {
167     FIXME("\n");
168     return E_NOTIMPL;
169 }
170 
171 static HRESULT WINAPI automatic_updates_get_ServiceEnabled(
172     IAutomaticUpdates *This,
173     VARIANT_BOOL *retval )
174 {
175     FIXME("%p\n", retval);
176     return E_NOTIMPL;
177 }
178 
179 static HRESULT WINAPI automatic_updates_get_Settings(
180     IAutomaticUpdates *This,
181     IAutomaticUpdatesSettings **retval )
182 {
183     FIXME("%p\n", retval);
184     return E_NOTIMPL;
185 }
186 
187 static const struct IAutomaticUpdatesVtbl automatic_updates_vtbl =
188 {
189     automatic_updates_QueryInterface,
190     automatic_updates_AddRef,
191     automatic_updates_Release,
192     automatic_updates_GetTypeInfoCount,
193     automatic_updates_GetTypeInfo,
194     automatic_updates_GetIDsOfNames,
195     automatic_updates_Invoke,
196     automatic_updates_DetectNow,
197     automatic_updates_Pause,
198     automatic_updates_Resume,
199     automatic_updates_ShowSettingsDialog,
200     automatic_updates_get_Settings,
201     automatic_updates_get_ServiceEnabled,
202     automatic_updates_EnableService
203 };
204 
205 HRESULT AutomaticUpdates_create( IUnknown *pUnkOuter, LPVOID *ppObj )
206 {
207     automatic_updates *updates;
208 
209     TRACE("(%p,%p)\n", pUnkOuter, ppObj);
210 
211     updates = HeapAlloc( GetProcessHeap(), 0, sizeof(*updates) );
212     if (!updates) return E_OUTOFMEMORY;
213 
214     updates->vtbl = &automatic_updates_vtbl;
215     updates->refs = 1;
216 
217     *ppObj = &updates->vtbl;
218 
219     TRACE("returning iface %p\n", *ppObj);
220     return S_OK;
221 }
222 

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~ [ freetext search ] ~ [ file search ] ~

This page was automatically generated by the LXR engine.
Visit the LXR main site for more information.