mshtml: Added IDOMEvent::get_type implementation.

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-01 17:02:06 +01:00 committed by Alexandre Julliard
parent d121009f24
commit dc5aefcebb
2 changed files with 16 additions and 2 deletions

View File

@ -1033,8 +1033,17 @@ static HRESULT WINAPI DOMEvent_get_timeStamp(IDOMEvent *iface, ULONGLONG *p)
static HRESULT WINAPI DOMEvent_get_type(IDOMEvent *iface, BSTR *p)
{
DOMEvent *This = impl_from_IDOMEvent(iface);
FIXME("(%p)->(%p)\n", This, p);
return E_NOTIMPL;
TRACE("(%p)->(%p)\n", This, p);
if(This->type) {
*p = SysAllocString(This->type);
if(!*p)
return E_OUTOFMEMORY;
}else {
*p = NULL;
}
return S_OK;
}
static HRESULT WINAPI DOMEvent_initEvent(IDOMEvent *iface, BSTR type, VARIANT_BOOL can_bubble, VARIANT_BOOL cancelable)

View File

@ -2693,6 +2693,11 @@ static void test_create_event(IHTMLDocument2 *doc)
hres = IDOMEvent_stopPropagation(event);
ok(hres == S_OK, "stopPropagation failed: %08x\n", hres);
str = (void*)0xdeadbeef;
hres = IDOMEvent_get_type(event, &str);
ok(hres == S_OK, "get_type failed: %08x\n", hres);
ok(!str, "type = %s\n", wine_dbgstr_w(str));
IDOMEvent_Release(event);
IDocumentEvent_Release(doc_event);