mshtml: Expose IDocumentEvent to scripts.

Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Jacek Caban 2017-12-04 18:02:11 +01:00 committed by Alexandre Julliard
parent d6d23a5339
commit 49679eb97b
3 changed files with 5 additions and 1 deletions

View File

@ -5107,8 +5107,10 @@ static void HTMLDocumentNode_init_dispex_info(dispex_data_t *info, compat_mode_t
{
HTMLDOMNode_init_dispex_info(info, mode);
if(mode >= COMPAT_MODE_IE9)
if(mode >= COMPAT_MODE_IE9) {
dispex_info_add_interface(info, IHTMLDocument7_tid, NULL);
dispex_info_add_interface(info, IDocumentEvent_tid, NULL);
}
/* Depending on compatibility version, we add interfaces in different order
* so that the right getElementById implementation is used. */

View File

@ -126,6 +126,7 @@ typedef struct EventTarget EventTarget;
XDIID(HTMLDocumentEvents) \
XDIID(HTMLElementEvents2) \
XIID(IDOMEvent) \
XIID(IDocumentEvent) \
XIID(IDocumentSelector) \
XIID(IElementSelector) \
XIID(IElementTraversal) \

View File

@ -62,6 +62,7 @@ function test_doc_props() {
test_exposed("addEventListener", v >= 9);
test_exposed("removeEventListener", v >= 9);
test_exposed("dispatchEvent", v >= 9);
test_exposed("createEvent", v >= 9);
test_exposed("parentWindow", true);
if(v >= 9) ok(document.defaultView === document.parentWindow, "defaultView != parentWindow");