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

shdocvw: Added WebBrowser::get_Application implementation.

parent 075e84bd
......@@ -984,6 +984,7 @@ static void test_ClassInfo(IUnknown *unk)
static void test_ie_funcs(IUnknown *unk)
{
IWebBrowser2 *wb;
IDispatch *disp;
VARIANT_BOOL b;
int i;
long hwnd;
......@@ -1134,6 +1135,18 @@ static void test_ie_funcs(IUnknown *unk)
ok(hres == E_NOTIMPL, "get_Resizable failed: %08x\n", hres);
ok(b == 0x100, "b=%x\n", b);
/* Application */
disp = NULL;
hres = IWebBrowser2_get_Application(wb, &disp);
ok(hres == S_OK, "get_Application failed: %08x\n", hres);
ok(disp == (void*)wb, "disp=%p, expected %p\n", disp, wb);
if(disp)
IDispatch_Release(disp);
hres = IWebBrowser2_get_Application(wb, NULL);
ok(hres == E_POINTER, "get_Application failed: %08x, expected E_POINTER\n", hres);
IWebBrowser2_Release(wb);
}
......
......@@ -260,8 +260,15 @@ static HRESULT WINAPI WebBrowser_Stop(IWebBrowser2 *iface)
static HRESULT WINAPI WebBrowser_get_Application(IWebBrowser2 *iface, IDispatch **ppDisp)
{
WebBrowser *This = WEBBROWSER_THIS(iface);
FIXME("(%p)->(%p)\n", This, ppDisp);
return E_NOTIMPL;
TRACE("(%p)->(%p)\n", This, ppDisp);
if(!ppDisp)
return E_POINTER;
*ppDisp = (IDispatch*)WEBBROWSER2(This);
IDispatch_AddRef(*ppDisp);
return S_OK;
}
static HRESULT WINAPI WebBrowser_get_Parent(IWebBrowser2 *iface, IDispatch **ppDisp)
......
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