Commit 52a1065f authored by Piotr Caban's avatar Piotr Caban Committed by Alexandre Julliard

mshtml: Added IObjectSafety stub.

parent 862eab28
...@@ -1827,6 +1827,9 @@ static BOOL htmldoc_qi(HTMLDocument *This, REFIID riid, void **ppv) ...@@ -1827,6 +1827,9 @@ static BOOL htmldoc_qi(HTMLDocument *This, REFIID riid, void **ppv)
}else if(IsEqualGUID(&IID_IOleContainer, riid)) { }else if(IsEqualGUID(&IID_IOleContainer, riid)) {
TRACE("(%p)->(IID_IOleContainer %p)\n", This, ppv); TRACE("(%p)->(IID_IOleContainer %p)\n", This, ppv);
*ppv = &This->IOleContainer_iface; *ppv = &This->IOleContainer_iface;
}else if(IsEqualGUID(&IID_IObjectSafety, riid)) {
TRACE("(%p)->(IID_IObjectSafety %p)\n", This, ppv);
*ppv = &This->IObjectSafety_iface;
}else { }else {
return FALSE; return FALSE;
} }
......
...@@ -66,6 +66,7 @@ HKLM,"Software\Microsoft\Internet Explorer\AboutURLs","PostNotCached",2,"res://m ...@@ -66,6 +66,7 @@ HKLM,"Software\Microsoft\Internet Explorer\AboutURLs","PostNotCached",2,"res://m
HKLM,"Software\Microsoft\Internet Explorer\AboutURLs","mozilla",2,"res://mshtml.dll/about.moz" HKLM,"Software\Microsoft\Internet Explorer\AboutURLs","mozilla",2,"res://mshtml.dll/about.moz"
HKLM,"Software\Microsoft\Internet Explorer\Default Behaviors","VML",, "CLSID:10072CEC-8CC1-11D1-986E-00A0C955B42E" HKLM,"Software\Microsoft\Internet Explorer\Default Behaviors","VML",, "CLSID:10072CEC-8CC1-11D1-986E-00A0C955B42E"
HKLM,"Software\Microsoft\Internet Explorer\Default Behaviors","TIME",, "CLSID:476C391C-3E0D-11D2-B948-00C04FA32195" HKLM,"Software\Microsoft\Internet Explorer\Default Behaviors","TIME",, "CLSID:476C391C-3E0D-11D2-B948-00C04FA32195"
HKLM,"Software\Microsoft\Internet Explorer\ActiveX Compatibility","Version",,"6.17"
[WineGecko.Reg] [WineGecko.Reg]
......
...@@ -24,6 +24,7 @@ ...@@ -24,6 +24,7 @@
#include "hlink.h" #include "hlink.h"
#include "perhist.h" #include "perhist.h"
#include "dispex.h" #include "dispex.h"
#include "objsafe.h"
#include "wine/list.h" #include "wine/list.h"
#include "wine/unicode.h" #include "wine/unicode.h"
...@@ -368,6 +369,7 @@ struct HTMLDocument { ...@@ -368,6 +369,7 @@ struct HTMLDocument {
ISupportErrorInfo ISupportErrorInfo_iface; ISupportErrorInfo ISupportErrorInfo_iface;
IObjectWithSite IObjectWithSite_iface; IObjectWithSite IObjectWithSite_iface;
IOleContainer IOleContainer_iface; IOleContainer IOleContainer_iface;
IObjectSafety IObjectSafety_iface;
IUnknown *unk_impl; IUnknown *unk_impl;
IDispatchEx *dispex; IDispatchEx *dispex;
......
...@@ -802,6 +802,10 @@ static const IObjectWithSiteVtbl ObjectWithSiteVtbl = { ...@@ -802,6 +802,10 @@ static const IObjectWithSiteVtbl ObjectWithSiteVtbl = {
ObjectWithSite_GetSite ObjectWithSite_GetSite
}; };
/**********************************************************
* IOleContainer implementation
*/
static inline HTMLDocument *impl_from_IOleContainer(IOleContainer *iface) static inline HTMLDocument *impl_from_IOleContainer(IOleContainer *iface)
{ {
return CONTAINING_RECORD(iface, HTMLDocument, IOleContainer_iface); return CONTAINING_RECORD(iface, HTMLDocument, IOleContainer_iface);
...@@ -856,6 +860,63 @@ static const IOleContainerVtbl OleContainerVtbl = { ...@@ -856,6 +860,63 @@ static const IOleContainerVtbl OleContainerVtbl = {
OleContainer_LockContainer OleContainer_LockContainer
}; };
/**********************************************************
* IObjectSafety implementation
*/
static inline HTMLDocument *impl_from_IObjectSafety(IObjectSafety *iface)
{
return CONTAINING_RECORD(iface, HTMLDocument, IObjectSafety_iface);
}
static HRESULT WINAPI ObjectSafety_QueryInterface(IObjectSafety *iface, REFIID riid, void **ppv)
{
HTMLDocument *This = impl_from_IObjectSafety(iface);
return htmldoc_query_interface(This, riid, ppv);
}
static ULONG WINAPI ObjectSafety_AddRef(IObjectSafety *iface)
{
HTMLDocument *This = impl_from_IObjectSafety(iface);
return htmldoc_addref(This);
}
static ULONG WINAPI ObjectSafety_Release(IObjectSafety *iface)
{
HTMLDocument *This = impl_from_IObjectSafety(iface);
return htmldoc_release(This);
}
static HRESULT WINAPI ObjectSafety_GetInterfaceSafetyOptions(IObjectSafety *iface,
REFIID riid, DWORD *pdwSupportedOptions, DWORD *pdwEnabledOptions)
{
HTMLDocument *This = impl_from_IObjectSafety(iface);
FIXME("(%p)->(%s %p %p)\n", This, debugstr_guid(riid), pdwSupportedOptions, pdwEnabledOptions);
return E_NOTIMPL;
}
static HRESULT WINAPI ObjectSafety_SetInterfaceSafetyOptions(IObjectSafety *iface,
REFIID riid, DWORD dwOptionSetMask, DWORD dwEnabledOptions)
{
HTMLDocument *This = impl_from_IObjectSafety(iface);
FIXME("(%p)->(%s %x %x)\n", This, debugstr_guid(riid), dwOptionSetMask, dwEnabledOptions);
if(IsEqualGUID(&IID_IPersistMoniker, riid) &&
dwOptionSetMask==INTERFACESAFE_FOR_UNTRUSTED_DATA &&
dwEnabledOptions==INTERFACESAFE_FOR_UNTRUSTED_DATA)
return S_OK;
return E_NOTIMPL;
}
static const IObjectSafetyVtbl ObjectSafetyVtbl = {
ObjectSafety_QueryInterface,
ObjectSafety_AddRef,
ObjectSafety_Release,
ObjectSafety_GetInterfaceSafetyOptions,
ObjectSafety_SetInterfaceSafetyOptions
};
void HTMLDocument_LockContainer(HTMLDocumentObj *This, BOOL fLock) void HTMLDocument_LockContainer(HTMLDocumentObj *This, BOOL fLock)
{ {
IOleContainer *container; IOleContainer *container;
...@@ -879,4 +940,5 @@ void HTMLDocument_OleObj_Init(HTMLDocument *This) ...@@ -879,4 +940,5 @@ void HTMLDocument_OleObj_Init(HTMLDocument *This)
This->IOleControl_iface.lpVtbl = &OleControlVtbl; This->IOleControl_iface.lpVtbl = &OleControlVtbl;
This->IObjectWithSite_iface.lpVtbl = &ObjectWithSiteVtbl; This->IObjectWithSite_iface.lpVtbl = &ObjectWithSiteVtbl;
This->IOleContainer_iface.lpVtbl = &OleContainerVtbl; This->IOleContainer_iface.lpVtbl = &OleContainerVtbl;
This->IObjectSafety_iface.lpVtbl = &ObjectSafetyVtbl;
} }
...@@ -32,6 +32,7 @@ ...@@ -32,6 +32,7 @@
#include "docobj.h" #include "docobj.h"
#include "dispex.h" #include "dispex.h"
#include "mshtml_test.h" #include "mshtml_test.h"
#include "objsafe.h"
static const char doc_blank[] = "<html></html>"; static const char doc_blank[] = "<html></html>";
static const char doc_str1[] = "<html><body>test</body></html>"; static const char doc_str1[] = "<html><body>test</body></html>";
...@@ -126,6 +127,7 @@ static const IID * const doc_node_iids[] = { ...@@ -126,6 +127,7 @@ static const IID * const doc_node_iids[] = {
&IID_IConnectionPointContainer, &IID_IConnectionPointContainer,
&IID_IInternetHostSecurityManager, &IID_IInternetHostSecurityManager,
&IID_IOleContainer, &IID_IOleContainer,
&IID_IObjectSafety,
NULL NULL
}; };
...@@ -139,6 +141,7 @@ static const IID * const doc_obj_iids[] = { ...@@ -139,6 +141,7 @@ static const IID * const doc_obj_iids[] = {
&IID_IConnectionPointContainer, &IID_IConnectionPointContainer,
&IID_ICustomDoc, &IID_ICustomDoc,
&IID_IOleContainer, &IID_IOleContainer,
&IID_IObjectSafety,
NULL NULL
}; };
......
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