Jacek Caban : shdocvw: Added test of GetControlInfo.

Alexandre Julliard julliard at wine.codeweavers.com
Fri Jul 28 07:15:11 CDT 2006


Module: wine
Branch: refs/heads/master
Commit: 89b443d55904ce5f88caea3ae71e2af3f5ff18f1
URL:    http://source.winehq.org/git/?p=wine.git;a=commit;h=89b443d55904ce5f88caea3ae71e2af3f5ff18f1

Author: Jacek Caban <jacek at codeweavers.com>
Date:   Thu Jul 27 23:30:36 2006 +0200

shdocvw: Added test of GetControlInfo.

---

 dlls/shdocvw/oleobject.c        |    5 ++++-
 dlls/shdocvw/tests/webbrowser.c |   20 ++++++++++++++++++++
 2 files changed, 24 insertions(+), 1 deletions(-)

diff --git a/dlls/shdocvw/oleobject.c b/dlls/shdocvw/oleobject.c
index dc790b3..c50b302 100644
--- a/dlls/shdocvw/oleobject.c
+++ b/dlls/shdocvw/oleobject.c
@@ -607,7 +607,10 @@ static ULONG WINAPI OleControl_Release(I
 static HRESULT WINAPI OleControl_GetControlInfo(IOleControl *iface, LPCONTROLINFO pCI)
 {
     WebBrowser *This = CONTROL_THIS(iface);
-    FIXME("(%p)->(%p)\n", This, pCI);
+
+    TRACE("(%p)->(%p)\n", This, pCI);
+
+    /* Tests show that this function should be not implemented */
     return E_NOTIMPL;
 }
 
diff --git a/dlls/shdocvw/tests/webbrowser.c b/dlls/shdocvw/tests/webbrowser.c
index 7fa58c0..ce9cae4 100644
--- a/dlls/shdocvw/tests/webbrowser.c
+++ b/dlls/shdocvw/tests/webbrowser.c
@@ -809,6 +809,25 @@ static void test_ie_funcs(IUnknown *unk)
     IWebBrowser2_Release(wb);
 }
 
+static void test_GetControlInfo(IUnknown *unk)
+{
+    IOleControl *control;
+    CONTROLINFO info;
+    HRESULT hres;
+
+    hres = IUnknown_QueryInterface(unk, &IID_IOleControl, (void**)&control);
+    ok(hres == S_OK, "Could not get IOleControl: %08lx\n", hres);
+    if(FAILED(hres))
+        return;
+
+    hres = IOleControl_GetControlInfo(control, &info);
+    ok(hres == E_NOTIMPL, "GetControlInfo failed: %08lx, exxpected E_NOTIMPL\n", hres);
+    hres = IOleControl_GetControlInfo(control, NULL);
+    ok(hres == E_NOTIMPL, "GetControlInfo failed: %08lx, exxpected E_NOTIMPL\n", hres);
+
+    IOleControl_Release(control);
+}
+
 static void test_WebBrowser(void)
 {
     IUnknown *unk = NULL;
@@ -826,6 +845,7 @@ static void test_WebBrowser(void)
     test_DoVerb(unk);
     test_ClientSite(unk, NULL);
     test_ie_funcs(unk);
+    test_GetControlInfo(unk);
 
     ref = IUnknown_Release(unk);
     ok(ref == 0, "ref=%ld, expected 0\n", ref);




More information about the wine-cvs mailing list