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

mshtml: Expose IHTMLDOMNode3 interface to scripts.

parent 03b80411
......@@ -5176,6 +5176,8 @@ void HTMLElement_init_dispex_info(dispex_data_t *info, compat_mode_t mode)
{
static const DISPID elem2_ie11_blacklist[] = {DISPID_IHTMLELEMENT2_DOSCROLL, DISPID_UNKNOWN};
HTMLDOMNode_init_dispex_info(info, mode);
dispex_info_add_interface(info, IHTMLElement2_tid, mode >= COMPAT_MODE_IE11 ? elem2_ie11_blacklist : NULL);
if(mode >= COMPAT_MODE_IE8)
......
......@@ -436,7 +436,8 @@ static const tid_t HTMLDOMChildrenCollection_iface_tids[] = {
static dispex_static_data_t HTMLDOMChildrenCollection_dispex = {
&HTMLDOMChildrenCollection_dispex_vtbl,
DispDOMChildrenCollection_tid,
HTMLDOMChildrenCollection_iface_tids
HTMLDOMChildrenCollection_iface_tids,
HTMLDOMNode_init_dispex_info
};
IHTMLDOMChildrenCollection *create_child_collection(HTMLDocumentNode *doc, nsIDOMNodeList *nslist)
......@@ -1401,6 +1402,12 @@ static HRESULT HTMLDOMNode_clone(HTMLDOMNode *This, nsIDOMNode *nsnode, HTMLDOMN
return create_node(This->doc, nsnode, ret);
}
void HTMLDOMNode_init_dispex_info(dispex_data_t *info, compat_mode_t mode)
{
if(mode >= COMPAT_MODE_IE9)
dispex_info_add_interface(info, IHTMLDOMNode3_tid, NULL);
}
static const cpc_entry_t HTMLDOMNode_cpc[] = {{NULL}};
static const NodeImplVtbl HTMLDOMNodeImplVtbl = {
......
......@@ -361,7 +361,8 @@ static const tid_t HTMLDOMTextNode_iface_tids[] = {
static dispex_static_data_t HTMLDOMTextNode_dispex = {
NULL,
DispHTMLDOMTextNode_tid,
HTMLDOMTextNode_iface_tids
HTMLDOMTextNode_iface_tids,
HTMLDOMNode_init_dispex_info
};
HRESULT HTMLDOMTextNode_Create(HTMLDocumentNode *doc, nsIDOMNode *nsnode, HTMLDOMNode **node)
......@@ -377,8 +378,8 @@ HRESULT HTMLDOMTextNode_Create(HTMLDocumentNode *doc, nsIDOMNode *nsnode, HTMLDO
ret->IHTMLDOMTextNode_iface.lpVtbl = &HTMLDOMTextNodeVtbl;
ret->IHTMLDOMTextNode2_iface.lpVtbl = &HTMLDOMTextNode2Vtbl;
init_dispex(&ret->node.event_target.dispex, (IUnknown*)&ret->IHTMLDOMTextNode_iface,
&HTMLDOMTextNode_dispex);
init_dispex_with_compat_mode(&ret->node.event_target.dispex, (IUnknown*)&ret->IHTMLDOMTextNode_iface,
&HTMLDOMTextNode_dispex, doc->document_mode);
HTMLDOMNode_Init(doc, &ret->node, nsnode);
......
......@@ -151,6 +151,7 @@ typedef struct EventTarget EventTarget;
XIID(IHTMLDOMImplementation) \
XIID(IHTMLDOMNode) \
XIID(IHTMLDOMNode2) \
XIID(IHTMLDOMNode3) \
XIID(IHTMLDOMTextNode) \
XIID(IHTMLDOMTextNode2) \
XIID(IHTMLElement) \
......@@ -1039,6 +1040,7 @@ void HTMLFrameBase_Init(HTMLFrameBase*,HTMLDocumentNode*,nsIDOMHTMLElement*,disp
HRESULT HTMLDOMNode_QI(HTMLDOMNode*,REFIID,void**) DECLSPEC_HIDDEN;
void HTMLDOMNode_destructor(HTMLDOMNode*) DECLSPEC_HIDDEN;
void HTMLDOMNode_init_dispex_info(dispex_data_t*,compat_mode_t) DECLSPEC_HIDDEN;
HRESULT HTMLElement_QI(HTMLDOMNode*,REFIID,void**) DECLSPEC_HIDDEN;
void HTMLElement_destructor(HTMLDOMNode*) DECLSPEC_HIDDEN;
......
......@@ -32,6 +32,8 @@ function test_elem_props() {
test_exposed("doScroll", v < 11);
test_exposed("querySelectorAll", v >= 8);
test_exposed("textContent", v >= 9);
test_exposed("prefix", v >= 9);
next_test();
}
......
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