forked from enlightenment/efl
ecore-wl2: Add API function to set pointer surface on a window
Signed-off-by: Chris Michael <cp.michael@samsung.com>
This commit is contained in:
parent
d8f72b6c32
commit
590c278a46
|
@ -430,6 +430,8 @@ EAPI void ecore_wl2_window_iconified_set(Ecore_Wl2_Window *window, Eina_Bool ico
|
|||
/* TODO: doxy */
|
||||
EAPI void ecore_wl2_window_pointer_xy_get(Ecore_Wl2_Window *window, int *x, int *y);
|
||||
|
||||
EAPI void ecore_wl2_window_pointer_set(Ecore_Wl2_Window *window, struct wl_surface *surface, int hot_x, int hot_y);
|
||||
|
||||
/* # ifdef __cplusplus */
|
||||
/* } */
|
||||
/* # endif */
|
||||
|
|
|
@ -798,3 +798,15 @@ ecore_wl2_window_pointer_xy_get(Ecore_Wl2_Window *window, int *x, int *y)
|
|||
if (x) *x = window->input->pointer.sx;
|
||||
if (y) *y = window->input->pointer.sy;
|
||||
}
|
||||
|
||||
EAPI void
|
||||
ecore_wl2_window_pointer_set(Ecore_Wl2_Window *window, struct wl_surface *surface, int hot_x, int hot_y)
|
||||
{
|
||||
EINA_SAFETY_ON_NULL_RETURN(window);
|
||||
EINA_SAFETY_ON_NULL_RETURN(window->input);
|
||||
|
||||
if (window->input->wl.pointer)
|
||||
wl_pointer_set_cursor(window->input->wl.pointer,
|
||||
window->input->pointer.enter_serial,
|
||||
surface, hot_x, hot_y);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue