2 * Implementation of IProvideClassInfo interfaces for IE Web Browser control
4 * 2001 John R. Sheets (for CodeWeavers)
8 #include "debugtools.h"
11 DEFAULT_DEBUG_CHANNEL(shdocvw
);
13 /**********************************************************************
14 * Implement the IProvideClassInfo interface
16 * FIXME: Should we just pass in the IProvideClassInfo2 methods rather
17 * reimplementing them here?
20 static HRESULT WINAPI
WBPCI_QueryInterface(LPPROVIDECLASSINFO iface
,
21 REFIID riid
, LPVOID
*ppobj
)
23 ICOM_THIS(IProvideClassInfoImpl
, iface
);
25 FIXME("(%p)->(%s,%p),stub!\n", This
, debugstr_guid(riid
), ppobj
);
29 static ULONG WINAPI
WBPCI_AddRef(LPPROVIDECLASSINFO iface
)
31 ICOM_THIS(IProvideClassInfoImpl
, iface
);
37 static ULONG WINAPI
WBPCI_Release(LPPROVIDECLASSINFO iface
)
39 ICOM_THIS(IProvideClassInfoImpl
, iface
);
41 /* static class, won't be freed */
46 /* Return an ITypeInfo interface to retrieve type library info about
49 static HRESULT WINAPI
WBPCI_GetClassInfo(LPPROVIDECLASSINFO iface
, LPTYPEINFO
*ppTI
)
51 FIXME("stub: LPTYPEINFO = %p\n", *ppTI
);
55 /**********************************************************************
56 * IProvideClassInfo virtual function table for IE Web Browser component
59 static ICOM_VTABLE(IProvideClassInfo
) WBPCI_Vtbl
=
61 ICOM_MSVTABLE_COMPAT_DummyRTTIVALUE
68 IProvideClassInfoImpl SHDOCVW_ProvideClassInfo
= { &WBPCI_Vtbl
, 1 };
71 /**********************************************************************
72 * Implement the IProvideClassInfo2 interface (inherits from
76 static HRESULT WINAPI
WBPCI2_QueryInterface(LPPROVIDECLASSINFO2 iface
,
77 REFIID riid
, LPVOID
*ppobj
)
79 ICOM_THIS(IProvideClassInfo2Impl
, iface
);
81 FIXME("(%p)->(%s,%p),stub!\n", This
, debugstr_guid(riid
), ppobj
);
85 static ULONG WINAPI
WBPCI2_AddRef(LPPROVIDECLASSINFO2 iface
)
87 ICOM_THIS(IProvideClassInfo2Impl
, iface
);
93 static ULONG WINAPI
WBPCI2_Release(LPPROVIDECLASSINFO2 iface
)
95 ICOM_THIS(IProvideClassInfo2Impl
, iface
);
97 /* static class, won't be freed */
102 /* Return an ITypeInfo interface to retrieve type library info about
105 static HRESULT WINAPI
WBPCI2_GetClassInfo(LPPROVIDECLASSINFO2 iface
, LPTYPEINFO
*ppTI
)
107 FIXME("stub: LPTYPEINFO = %p\n", *ppTI
);
111 /* Get the IID for generic default event callbacks. This IID will
112 * in theory be used to later query for an IConnectionPoint to connect
113 * an event sink (callback implmentation in the OLE control site)
116 static HRESULT WINAPI
WBPCI2_GetGUID(LPPROVIDECLASSINFO2 iface
,
117 DWORD dwGuidKind
, GUID
*pGUID
)
119 FIXME("stub: dwGuidKind = %ld, pGUID = %s\n", dwGuidKind
, debugstr_guid(pGUID
));
121 if (dwGuidKind
!= GUIDKIND_DEFAULT_SOURCE_DISP_IID
)
123 FIXME ("Requested unsupported GUID type: %ld\n", dwGuidKind
);
124 return E_FAIL
; /* Is there a better return type here? */
127 /* FIXME: Returning IPropertyNotifySink interface, but should really
128 * return a more generic event set (???) dispinterface.
129 * However, this hack, allows a control site to return with success
130 * (MFC's COleControlSite falls back to older IProvideClassInfo interface
131 * if GetGUID() fails to return a non-NULL GUID).
133 memcpy(pGUID
, &IID_IPropertyNotifySink
, sizeof(GUID
));
134 FIXME("Wrongly returning IPropertyNotifySink interface %s\n",
135 debugstr_guid(pGUID
));
140 /**********************************************************************
141 * IProvideClassInfo virtual function table for IE Web Browser component
144 static ICOM_VTABLE(IProvideClassInfo2
) WBPCI2_Vtbl
=
146 ICOM_MSVTABLE_COMPAT_DummyRTTIVALUE
147 WBPCI2_QueryInterface
,
154 IProvideClassInfo2Impl SHDOCVW_ProvideClassInfo2
= { &WBPCI2_Vtbl
, 1 };