Alistair Leslie-Hughes : mshtml: Show IPersistHistory interface is supported.

Alexandre Julliard julliard at winehq.org
Fri Feb 27 10:02:47 CST 2009


Module: wine
Branch: master
Commit: b30aa168f7034e5d5c73ca4ce64bcf015e58f223
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=b30aa168f7034e5d5c73ca4ce64bcf015e58f223

Author: Alistair Leslie-Hughes <leslie_alistair at hotmail.com>
Date:   Thu Feb 26 21:39:36 2009 +1100

mshtml: Show IPersistHistory interface is supported.

---

 dlls/mshtml/htmldoc.c       |    4 ++++
 dlls/mshtml/tests/htmldoc.c |   22 ++++++++++++++++++++++
 2 files changed, 26 insertions(+), 0 deletions(-)

diff --git a/dlls/mshtml/htmldoc.c b/dlls/mshtml/htmldoc.c
index a6aa73f..ea99445 100644
--- a/dlls/mshtml/htmldoc.c
+++ b/dlls/mshtml/htmldoc.c
@@ -27,6 +27,7 @@
 #include "winbase.h"
 #include "winuser.h"
 #include "ole2.h"
+#include "perhist.h"
 
 #include "wine/debug.h"
 
@@ -132,6 +133,9 @@ static HRESULT WINAPI HTMLDocument_QueryInterface(IHTMLDocument2 *iface, REFIID
     }else if(IsEqualGUID(&IID_ISupportErrorInfo, riid)) {
         TRACE("(%p)->(IID_ISupportErrorInfo %p)\n", This, ppvObject);
         *ppvObject = SUPPERRINFO(This);
+    }else if(IsEqualGUID(&IID_IPersistHistory, riid)) {
+        FIXME("(%p)->(IID_IPersistHistory currently not supported %p)\n", This, ppvObject);
+        *ppvObject = NULL;
     }else if(IsEqualGUID(&CLSID_CMarkup, riid)) {
         FIXME("(%p)->(CLSID_CMarkup %p)\n", This, ppvObject);
         return E_NOINTERFACE;
diff --git a/dlls/mshtml/tests/htmldoc.c b/dlls/mshtml/tests/htmldoc.c
index e4ae144..daac740 100644
--- a/dlls/mshtml/tests/htmldoc.c
+++ b/dlls/mshtml/tests/htmldoc.c
@@ -36,6 +36,7 @@
 #include "dispex.h"
 #include "idispids.h"
 #include "shlguid.h"
+#include "perhist.h"
 
 DEFINE_GUID(GUID_NULL,0,0,0,0,0,0,0,0,0,0,0);
 DEFINE_GUID(IID_IProxyManager,0x00000008,0x0000,0x0000,0xc0,0x00,0x00,0x00,0x00,0x00,0x00,0x46);
@@ -4160,6 +4161,26 @@ static void test_HTMLDoc_ISupportErrorInfo(void)
     ok(ref == 0, "ref=%d, expected 0\n", ref);
 }
 
+static void test_IPersistHistory(void)
+{
+    HRESULT hres;
+    IUnknown *unk;
+    LONG ref;
+    IPersistHistory *phist;
+
+    hres = create_document(&unk);
+    if(FAILED(hres))
+        return;
+
+    hres = IUnknown_QueryInterface(unk, &IID_IPersistHistory, (void**)&phist);
+    todo_wine ok(hres == S_OK, "QueryInterface returned %08x, expected S_OK\n", hres);
+    if(hres == S_OK)
+        IPersistHistory_Release(phist);
+
+    ref = IUnknown_Release(unk);
+    ok(ref == 0, "ref=%d, expected 0\n", ref);
+}
+
 START_TEST(htmldoc)
 {
     gecko_installer_workaround(TRUE);
@@ -4177,6 +4198,7 @@ START_TEST(htmldoc)
         test_editing_mode(TRUE);
     }
     test_HTMLDoc_ISupportErrorInfo();
+    test_IPersistHistory();
 
     DestroyWindow(container_hwnd);
     CoUninitialize();




More information about the wine-cvs mailing list