Module: wine Branch: master Commit: e174d1d31bd5c77f7d4c27f74392ff1747a13a91 URL: http://source.winehq.org/git/wine.git/?a=commit;h=e174d1d31bd5c77f7d4c27f743...
Author: Jacek Caban jacek@codeweavers.com Date: Fri Jan 20 15:10:25 2012 +0100
mshtml: Added ITravelLogClient stub implementation.
---
dlls/mshtml/htmlwindow.c | 60 ++++++++++++++++++++++++++++++++++++++++++ dlls/mshtml/mshtml_private.h | 2 + dlls/mshtml/tests/dom.c | 2 + dlls/mshtml/tests/htmldoc.c | 1 + 4 files changed, 65 insertions(+), 0 deletions(-)
diff --git a/dlls/mshtml/htmlwindow.c b/dlls/mshtml/htmlwindow.c index 654f2e0..7848b76 100644 --- a/dlls/mshtml/htmlwindow.c +++ b/dlls/mshtml/htmlwindow.c @@ -168,6 +168,9 @@ static HRESULT WINAPI HTMLWindow2_QueryInterface(IHTMLWindow2 *iface, REFIID rii }else if(IsEqualGUID(&IID_IServiceProvider, riid)) { TRACE("(%p)->(IID_IServiceProvider %p)\n", This, ppv); *ppv = &This->IServiceProvider_iface; + }else if(IsEqualGUID(&IID_ITravelLogClient, riid)) { + TRACE("(%p)->(IID_ITravelLogClient %p)\n", This, ppv); + *ppv = &This->ITravelLogClient_iface; }else if(dispex_query_interface(&This->dispex, riid, ppv)) { return *ppv ? S_OK : E_NOINTERFACE; } @@ -1945,6 +1948,62 @@ static const IHTMLPrivateWindowVtbl HTMLPrivateWindowVtbl = { HTMLPrivateWindow_GetAddressBarUrl };
+static inline HTMLWindow *impl_from_ITravelLogClient(ITravelLogClient *iface) +{ + return CONTAINING_RECORD(iface, HTMLWindow, ITravelLogClient_iface); +} + +static HRESULT WINAPI TravelLogClient_QueryInterface(ITravelLogClient *iface, REFIID riid, void **ppv) +{ + HTMLWindow *This = impl_from_ITravelLogClient(iface); + + return IHTMLWindow2_QueryInterface(&This->IHTMLWindow2_iface, riid, ppv); +} + +static ULONG WINAPI TravelLogClient_AddRef(ITravelLogClient *iface) +{ + HTMLWindow *This = impl_from_ITravelLogClient(iface); + + return IHTMLWindow2_AddRef(&This->IHTMLWindow2_iface); +} + +static ULONG WINAPI TravelLogClient_Release(ITravelLogClient *iface) +{ + HTMLWindow *This = impl_from_ITravelLogClient(iface); + + return IHTMLWindow2_Release(&This->IHTMLWindow2_iface); +} + +static HRESULT WINAPI TravelLogClient_FindWindowByIndex(ITravelLogClient *iface, DWORD dwID, IUnknown **ppunk) +{ + HTMLWindow *This = impl_from_ITravelLogClient(iface); + FIXME("(%p)->(%d %p)\n", This, dwID, ppunk); + return E_NOTIMPL; +} + +static HRESULT WINAPI TravelLogClient_GetWindowData(ITravelLogClient *iface, IStream *pStream, LPWINDOWDATA pWinData) +{ + HTMLWindow *This = impl_from_ITravelLogClient(iface); + FIXME("(%p)->(%p %p)\n", This, pStream, pWinData); + return E_NOTIMPL; +} + +static HRESULT WINAPI TravelLogClient_LoadHistoryPosition(ITravelLogClient *iface, LPWSTR pszUrlLocation, DWORD dwPosition) +{ + HTMLWindow *This = impl_from_ITravelLogClient(iface); + FIXME("(%p)->(%s %d)\n", This, debugstr_w(pszUrlLocation), dwPosition); + return E_NOTIMPL; +} + +static const ITravelLogClientVtbl TravelLogClientVtbl = { + TravelLogClient_QueryInterface, + TravelLogClient_AddRef, + TravelLogClient_Release, + TravelLogClient_FindWindowByIndex, + TravelLogClient_GetWindowData, + TravelLogClient_LoadHistoryPosition +}; + static inline HTMLWindow *impl_from_IDispatchEx(IDispatchEx *iface) { return CONTAINING_RECORD(iface, HTMLWindow, IDispatchEx_iface); @@ -2385,6 +2444,7 @@ HRESULT HTMLWindow_Create(HTMLDocumentObj *doc_obj, nsIDOMWindow *nswindow, HTML window->IHTMLPrivateWindow_iface.lpVtbl = &HTMLPrivateWindowVtbl; window->IDispatchEx_iface.lpVtbl = &WindowDispExVtbl; window->IServiceProvider_iface.lpVtbl = &ServiceProviderVtbl; + window->ITravelLogClient_iface.lpVtbl = &TravelLogClientVtbl; window->ref = 1; window->doc_obj = doc_obj;
diff --git a/dlls/mshtml/mshtml_private.h b/dlls/mshtml/mshtml_private.h index 684d396..90fab6d 100644 --- a/dlls/mshtml/mshtml_private.h +++ b/dlls/mshtml/mshtml_private.h @@ -27,6 +27,7 @@ #include "dispex.h" #include "objsafe.h" #include "htiframe.h" +#include "tlogstg.h"
#include "wine/list.h" #include "wine/unicode.h" @@ -294,6 +295,7 @@ struct HTMLWindow { IHTMLPrivateWindow IHTMLPrivateWindow_iface; IDispatchEx IDispatchEx_iface; IServiceProvider IServiceProvider_iface; + ITravelLogClient ITravelLogClient_iface;
LONG ref;
diff --git a/dlls/mshtml/tests/dom.c b/dlls/mshtml/tests/dom.c index 710b1f5..a847998 100644 --- a/dlls/mshtml/tests/dom.c +++ b/dlls/mshtml/tests/dom.c @@ -34,6 +34,7 @@ #include "mshtml_test.h" #include "objsafe.h" #include "htiface.h" +#include "tlogstg.h"
static INT (WINAPI *pLCIDToLocaleName)(LCID,LPWSTR,INT,DWORD); static LANGID (WINAPI *pGetUserDefaultUILanguage)(void); @@ -253,6 +254,7 @@ static const IID * const window_iids[] = { &IID_IHTMLWindow3, &IID_IDispatchEx, &IID_IServiceProvider, + &IID_ITravelLogClient, NULL };
diff --git a/dlls/mshtml/tests/htmldoc.c b/dlls/mshtml/tests/htmldoc.c index 85fbd9b..0177c16 100644 --- a/dlls/mshtml/tests/htmldoc.c +++ b/dlls/mshtml/tests/htmldoc.c @@ -42,6 +42,7 @@ #include "perhist.h" #include "shobjidl.h" #include "htiface.h" +#include "tlogstg.h" #include "mshtml_test.h"
DEFINE_GUID(GUID_NULL,0,0,0,0,0,0,0,0,0,0,0);