Commit 073a48ab authored by Jacek Caban's avatar Jacek Caban Committed by Alexandre Julliard

mshtml: Added PluginHost::GetWindowContext implementation.

parent 52cc865c
......@@ -47,6 +47,7 @@ C_SRCS = \
htmltextcont.c \
htmltextnode.c \
htmlwindow.c \
ipwindow.c \
loadopts.c \
main.c \
mutation.c \
......
......@@ -639,8 +639,41 @@ static HRESULT WINAPI PHInPlaceSite_GetWindowContext(IOleInPlaceSiteEx *iface,
RECT *lprcClipRect, OLEINPLACEFRAMEINFO *frame_info)
{
PluginHost *This = impl_from_IOleInPlaceSiteEx(iface);
FIXME("(%p)->(%p %p %p %p %p)\n", This, ppFrame, ppDoc, lprcPosRect, lprcClipRect, frame_info);
return E_NOTIMPL;
IOleInPlaceUIWindow *ip_window;
IOleInPlaceFrame *ip_frame;
RECT pr, cr;
HRESULT hres;
TRACE("(%p)->(%p %p %p %p %p)\n", This, ppFrame, ppDoc, lprcPosRect, lprcClipRect, frame_info);
if(!This->doc || !This->doc->basedoc.doc_obj || !This->doc->basedoc.doc_obj->ipsite) {
FIXME("No ipsite\n");
return E_UNEXPECTED;
}
hres = IOleInPlaceSite_GetWindowContext(This->doc->basedoc.doc_obj->ipsite, &ip_frame, &ip_window, &pr, &cr, frame_info);
if(FAILED(hres)) {
WARN("GetWindowContext failed: %08x\n", hres);
return hres;
}
if(ip_window)
IOleInPlaceUIWindow_Release(ip_window);
if(ip_frame)
IOleInPlaceFrame_Release(ip_frame);
hres = create_ip_frame(&ip_frame);
if(FAILED(hres))
return hres;
hres = create_ip_window(ppDoc);
if(FAILED(hres))
return hres;
*ppFrame = ip_frame;
*lprcPosRect = This->rect;
*lprcClipRect = This->rect;
return S_OK;
}
static HRESULT WINAPI PHInPlaceSite_Scroll(IOleInPlaceSiteEx *iface, SIZE scrollExtent)
......
......@@ -55,3 +55,6 @@ void update_plugin_window(PluginHost*,HWND,const RECT*);
void detach_plugin_host(PluginHost*);
HRESULT create_param_prop_bag(nsIDOMHTMLElement*,IPropertyBag**);
HRESULT create_ip_window(IOleInPlaceUIWindow**);
HRESULT create_ip_frame(IOleInPlaceFrame**);
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