mshtml: Improved IDOMMouseEvent::offset[XY] stubs.

Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Jacek Caban 2018-02-21 15:19:45 +01:00 committed by Alexandre Julliard
parent c586b759a9
commit cf6d34d815
2 changed files with 20 additions and 6 deletions

View File

@ -663,7 +663,10 @@ static HRESULT WINAPI HTMLEventObj_get_offsetX(IHTMLEventObj *iface, LONG *p)
{
HTMLEventObj *This = impl_from_IHTMLEventObj(iface);
FIXME("(%p)->(%p)\n", This, p);
TRACE("(%p)->(%p)\n", This, p);
if(This->event && This->event->mouse_event)
return IDOMMouseEvent_get_offsetX(&This->event->IDOMMouseEvent_iface, p);
*p = 0;
return S_OK;
@ -673,7 +676,10 @@ static HRESULT WINAPI HTMLEventObj_get_offsetY(IHTMLEventObj *iface, LONG *p)
{
HTMLEventObj *This = impl_from_IHTMLEventObj(iface);
FIXME("(%p)->(%p)\n", This, p);
TRACE("(%p)->(%p)\n", This, p);
if(This->event && This->event->mouse_event)
return IDOMMouseEvent_get_offsetY(&This->event->IDOMMouseEvent_iface, p);
*p = 0;
return S_OK;
@ -1598,15 +1604,21 @@ static HRESULT WINAPI DOMMouseEvent_get_y(IDOMMouseEvent *iface, LONG *p)
static HRESULT WINAPI DOMMouseEvent_get_offsetX(IDOMMouseEvent *iface, LONG *p)
{
DOMEvent *This = impl_from_IDOMMouseEvent(iface);
FIXME("(%p)->(%p)\n", This, p);
return E_NOTIMPL;
FIXME("(%p)->(%p) returning 0\n", This, p);
*p = 0;
return S_OK;
}
static HRESULT WINAPI DOMMouseEvent_get_offsetY(IDOMMouseEvent *iface, LONG *p)
{
DOMEvent *This = impl_from_IDOMMouseEvent(iface);
FIXME("(%p)->(%p)\n", This, p);
return E_NOTIMPL;
FIXME("(%p)->(%p) returning 0\n", This, p);
*p = 0;
return S_OK;
}
static HRESULT WINAPI DOMMouseEvent_get_pageX(IDOMMouseEvent *iface, LONG *p)

View File

@ -620,6 +620,8 @@ function test_mouse_event() {
ok(e.screenY === 0, "screenY = " + e.screenY);
ok(e.clientX === 0, "clientX = " + e.clientX);
ok(e.clientY === 0, "clientY = " + e.clientY);
ok(e.offsetX === 0, "offsetX = " + e.offsetX);
ok(e.offsetY === 0, "offsetY = " + e.offsetY);
ok(e.ctrlKey === false, "ctrlKey = " + e.ctrlKey);
ok(e.altKey === false, "altKey = " + e.altKey);
ok(e.shiftKey === false, "shiftKey = " + e.shiftKey);