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

mshtml: Added IHTMLEventObj::get_screen[XY] implementation.

parent be5e018b
...@@ -514,15 +514,45 @@ static HRESULT WINAPI HTMLEventObj_get_offsetY(IHTMLEventObj *iface, LONG *p) ...@@ -514,15 +514,45 @@ static HRESULT WINAPI HTMLEventObj_get_offsetY(IHTMLEventObj *iface, LONG *p)
static HRESULT WINAPI HTMLEventObj_get_screenX(IHTMLEventObj *iface, LONG *p) static HRESULT WINAPI HTMLEventObj_get_screenX(IHTMLEventObj *iface, LONG *p)
{ {
HTMLEventObj *This = HTMLEVENTOBJ_THIS(iface); HTMLEventObj *This = HTMLEVENTOBJ_THIS(iface);
FIXME("(%p)->(%p)\n", This, p); PRInt32 x = 0;
return E_NOTIMPL;
TRACE("(%p)->(%p)\n", This, p);
if(This->nsevent) {
nsIDOMMouseEvent *mouse_event;
nsresult nsres;
nsres = nsIDOMEvent_QueryInterface(This->nsevent, &IID_nsIDOMMouseEvent, (void**)&mouse_event);
if(NS_SUCCEEDED(nsres)) {
nsIDOMMouseEvent_GetScreenX(mouse_event, &x);
nsIDOMMouseEvent_Release(mouse_event);
}
}
*p = x;
return S_OK;
} }
static HRESULT WINAPI HTMLEventObj_get_screenY(IHTMLEventObj *iface, LONG *p) static HRESULT WINAPI HTMLEventObj_get_screenY(IHTMLEventObj *iface, LONG *p)
{ {
HTMLEventObj *This = HTMLEVENTOBJ_THIS(iface); HTMLEventObj *This = HTMLEVENTOBJ_THIS(iface);
FIXME("(%p)->(%p)\n", This, p); PRInt32 y = 0;
return E_NOTIMPL;
TRACE("(%p)->(%p)\n", This, p);
if(This->nsevent) {
nsIDOMMouseEvent *mouse_event;
nsresult nsres;
nsres = nsIDOMEvent_QueryInterface(This->nsevent, &IID_nsIDOMMouseEvent, (void**)&mouse_event);
if(NS_SUCCEEDED(nsres)) {
nsIDOMMouseEvent_GetScreenY(mouse_event, &y);
nsIDOMMouseEvent_Release(mouse_event);
}
}
*p = y;
return S_OK;
} }
static HRESULT WINAPI HTMLEventObj_get_srcFilter(IHTMLEventObj *iface, IDispatch **p) static HRESULT WINAPI HTMLEventObj_get_srcFilter(IHTMLEventObj *iface, IDispatch **p)
......
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