Commit dc25bca4 authored by Jacek Caban's avatar Jacek Caban Committed by Alexandre Julliard

mshtml: Added IOleContainer stub implementation.

parent 14f2d1b1
......@@ -1818,6 +1818,9 @@ static BOOL htmldoc_qi(HTMLDocument *This, REFIID riid, void **ppv)
}else if(IsEqualGUID(&IID_IObjectWithSite, riid)) {
TRACE("(%p)->(IID_IObjectWithSite %p)\n", This, ppv);
*ppv = OBJSITE(This);
}else if(IsEqualGUID(&IID_IOleContainer, riid)) {
TRACE("(%p)->(IID_IOleContainer %p)\n", This, ppv);
*ppv = &This->IOleContainer_iface;
}else {
return FALSE;
}
......
......@@ -365,6 +365,7 @@ struct HTMLDocument {
const IDispatchExVtbl *lpIDispatchExVtbl;
const ISupportErrorInfoVtbl *lpSupportErrorInfoVtbl;
const IObjectWithSiteVtbl *lpObjectWithSiteVtbl;
IOleContainer IOleContainer_iface;
IUnknown *unk_impl;
IDispatchEx *dispex;
......
......@@ -797,6 +797,60 @@ static const IObjectWithSiteVtbl ObjectWithSiteVtbl = {
ObjectWithSite_GetSite
};
static inline HTMLDocument *impl_from_IOleContainer(IOleContainer *iface)
{
return CONTAINING_RECORD(iface, HTMLDocument, IOleContainer_iface);
}
static HRESULT WINAPI OleContainer_QueryInterface(IOleContainer *iface, REFIID riid, void **ppv)
{
HTMLDocument *This = impl_from_IOleContainer(iface);
return IHTMLDocument2_QueryInterface(HTMLDOC(This), riid, ppv);
}
static ULONG WINAPI OleContainer_AddRef(IOleContainer *iface)
{
HTMLDocument *This = impl_from_IOleContainer(iface);
return IHTMLDocument2_AddRef(HTMLDOC(This));
}
static ULONG WINAPI OleContainer_Release(IOleContainer *iface)
{
HTMLDocument *This = impl_from_IOleContainer(iface);
return IHTMLDocument2_Release(HTMLDOC(This));
}
static HRESULT WINAPI OleContainer_ParseDisplayName(IOleContainer *iface, IBindCtx *pbc, LPOLESTR pszDisplayName,
ULONG *pchEaten, IMoniker **ppmkOut)
{
HTMLDocument *This = impl_from_IOleContainer(iface);
FIXME("(%p)->(%p %s %p %p)\n", This, pbc, debugstr_w(pszDisplayName), pchEaten, ppmkOut);
return E_NOTIMPL;
}
static HRESULT WINAPI OleContainer_EnumObjects(IOleContainer *iface, DWORD grfFlags, IEnumUnknown **ppenum)
{
HTMLDocument *This = impl_from_IOleContainer(iface);
FIXME("(%p)->(%x %p)\n", This, grfFlags, ppenum);
return E_NOTIMPL;
}
static HRESULT WINAPI OleContainer_LockContainer(IOleContainer *iface, BOOL fLock)
{
HTMLDocument *This = impl_from_IOleContainer(iface);
FIXME("(%p)->(%x)\n", This, fLock);
return E_NOTIMPL;
}
static const IOleContainerVtbl OleContainerVtbl = {
OleContainer_QueryInterface,
OleContainer_AddRef,
OleContainer_Release,
OleContainer_ParseDisplayName,
OleContainer_EnumObjects,
OleContainer_LockContainer
};
void HTMLDocument_LockContainer(HTMLDocumentObj *This, BOOL fLock)
{
IOleContainer *container;
......@@ -819,4 +873,5 @@ void HTMLDocument_OleObj_Init(HTMLDocument *This)
This->lpOleDocumentVtbl = &OleDocumentVtbl;
This->lpOleControlVtbl = &OleControlVtbl;
This->lpObjectWithSiteVtbl = &ObjectWithSiteVtbl;
This->IOleContainer_iface.lpVtbl = &OleContainerVtbl;
}
......@@ -125,6 +125,7 @@ static const IID * const doc_node_iids[] = {
&IID_IDispatchEx,
&IID_IConnectionPointContainer,
&IID_IInternetHostSecurityManager,
&IID_IOleContainer,
NULL
};
......@@ -137,6 +138,7 @@ static const IID * const doc_obj_iids[] = {
&IID_IDispatchEx,
&IID_IConnectionPointContainer,
&IID_ICustomDoc,
&IID_IOleContainer,
NULL
};
......@@ -267,6 +269,7 @@ static const IID * const window_iids[] = {
&IID_IHTMLWindow2,
&IID_IHTMLWindow3,
&IID_IDispatchEx,
&IID_IServiceProvider,
NULL
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment