Module: wine Branch: master Commit: feb957b2768e8864afc9946f1044cf251e311a61 URL: https://source.winehq.org/git/wine.git/?a=commit;h=feb957b2768e8864afc9946f1...
Author: Jacek Caban jacek@codeweavers.com Date: Mon Feb 5 17:29:59 2018 +0100
mshtml: Added IDOMMouseEvent position getters implementation.
Signed-off-by: Jacek Caban jacek@codeweavers.com Signed-off-by: Alexandre Julliard julliard@winehq.org
---
dlls/mshtml/htmlevent.c | 52 +++++++++++++++++++++++++++++++++++++++++-------- 1 file changed, 44 insertions(+), 8 deletions(-)
diff --git a/dlls/mshtml/htmlevent.c b/dlls/mshtml/htmlevent.c index 0cf69fb..e4ba0ed 100644 --- a/dlls/mshtml/htmlevent.c +++ b/dlls/mshtml/htmlevent.c @@ -1263,29 +1263,65 @@ static HRESULT WINAPI DOMMouseEvent_Invoke(IDOMMouseEvent *iface, DISPID dispIdM static HRESULT WINAPI DOMMouseEvent_get_screenX(IDOMMouseEvent *iface, LONG *p) { DOMEvent *This = impl_from_IDOMMouseEvent(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + INT32 screen_x; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsres = nsIDOMMouseEvent_GetScreenX(This->mouse_event, &screen_x); + if(NS_FAILED(nsres)) + return E_FAIL; + + *p = screen_x; + return S_OK; }
static HRESULT WINAPI DOMMouseEvent_get_screenY(IDOMMouseEvent *iface, LONG *p) { DOMEvent *This = impl_from_IDOMMouseEvent(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + INT32 screen_y; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsres = nsIDOMMouseEvent_GetScreenY(This->mouse_event, &screen_y); + if(NS_FAILED(nsres)) + return E_FAIL; + + *p = screen_y; + return S_OK; }
static HRESULT WINAPI DOMMouseEvent_get_clientX(IDOMMouseEvent *iface, LONG *p) { DOMEvent *This = impl_from_IDOMMouseEvent(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + INT32 client_x; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsres = nsIDOMMouseEvent_GetClientX(This->mouse_event, &client_x); + if(NS_FAILED(nsres)) + return E_FAIL; + + *p = client_x; + return S_OK; }
static HRESULT WINAPI DOMMouseEvent_get_clientY(IDOMMouseEvent *iface, LONG *p) { DOMEvent *This = impl_from_IDOMMouseEvent(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + INT32 client_y; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsres = nsIDOMMouseEvent_GetClientY(This->mouse_event, &client_y); + if(NS_FAILED(nsres)) + return E_FAIL; + + *p = client_y; + return S_OK; }
static HRESULT WINAPI DOMMouseEvent_get_ctrlKey(IDOMMouseEvent *iface, VARIANT_BOOL *p)