wuapi: Add class factory for CLSID_AutomaticUpdates.

This commit is contained in:
Hans Leidekker 2009-01-27 16:14:15 +01:00 committed by Alexandre Julliard
parent 68d19b9552
commit ecb5bdf901
2 changed files with 15 additions and 3 deletions

View file

@ -111,7 +111,8 @@ static const struct IClassFactoryVtbl wucf_vtbl =
wucf_LockServer
};
static wucf updatecf = { &wucf_vtbl, UpdateSession_create };
static wucf sessioncf = { &wucf_vtbl, UpdateSession_create };
static wucf updatescf = { &wucf_vtbl, AutomaticUpdates_create };
BOOL WINAPI DllMain( HINSTANCE hinst, DWORD reason, LPVOID lpv )
{
@ -135,8 +136,13 @@ HRESULT WINAPI DllGetClassObject( REFCLSID rclsid, REFIID iid, LPVOID *ppv )
TRACE("%s %s %p\n", debugstr_guid(rclsid), debugstr_guid(iid), ppv);
if (IsEqualGUID( rclsid, &CLSID_UpdateSession ))
cf = (IClassFactory *)&updatecf.vtbl;
{
cf = (IClassFactory *)&sessioncf.vtbl;
}
else if (IsEqualGUID( rclsid, &CLSID_AutomaticUpdates ))
{
cf = (IClassFactory *)&updatescf.vtbl;
}
if (!cf) return CLASS_E_CLASSNOTAVAILABLE;
return IClassFactory_QueryInterface( cf, iid, ppv );
}

View file

@ -383,6 +383,12 @@ static struct regsvr_coclass const coclass_list[] = {
"wuapi.dll",
"Both"
},
{ &CLSID_AutomaticUpdates,
"CLSID_AutomaticUpdates",
NULL,
"wuapi.dll",
"Both"
},
{ NULL } /* list terminator */
};