forked from enlightenment/efl
ecore-drm2: Add API functions to get and set pointer position
Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
This commit is contained in:
parent
d2b4176592
commit
296d233f64
|
@ -174,6 +174,30 @@ EAPI int ecore_drm2_device_clock_id_get(Ecore_Drm2_Device *device);
|
|||
*/
|
||||
EAPI void ecore_drm2_device_cursor_size_get(Ecore_Drm2_Device *device, int *width, int *height);
|
||||
|
||||
/**
|
||||
* Get the current pointer position
|
||||
*
|
||||
* @param device
|
||||
* @param x
|
||||
* @param y
|
||||
*
|
||||
* @ingroup Ecore_Drm2_Device_Group
|
||||
* @since 1.18
|
||||
*/
|
||||
EAPI void ecore_drm2_device_pointer_xy_get(Ecore_Drm2_Device *device, int *x, int *y);
|
||||
|
||||
/**
|
||||
* Warp the pointer position to given coordinates
|
||||
*
|
||||
* @param dev
|
||||
* @param x
|
||||
* @param y
|
||||
*
|
||||
* @ingroup Ecore_Drm2_Device_Group
|
||||
* @since 1.18
|
||||
*/
|
||||
EAPI void ecore_drm2_device_pointer_warp(Ecore_Drm2_Device *device, int x, int y);
|
||||
|
||||
/**
|
||||
* @defgroup Ecore_Drm2_Output_Group Drm output functions
|
||||
*
|
||||
|
|
|
@ -182,3 +182,22 @@ ecore_drm2_device_cursor_size_get(Ecore_Drm2_Device *device, int *width, int *he
|
|||
if (ret == 0) *height = caps;
|
||||
}
|
||||
}
|
||||
|
||||
EAPI void
|
||||
ecore_drm2_device_pointer_xy_get(Ecore_Drm2_Device *device, int *x, int *y)
|
||||
{
|
||||
if (x) *x = 0;
|
||||
if (y) *y = 0;
|
||||
|
||||
EINA_SAFETY_ON_NULL_RETURN(device);
|
||||
|
||||
elput_input_pointer_xy_get(device->em, NULL, x, y);
|
||||
}
|
||||
|
||||
EAPI void
|
||||
ecore_drm2_device_pointer_warp(Ecore_Drm2_Device *device, int x, int y)
|
||||
{
|
||||
EINA_SAFETY_ON_NULL_RETURN(device);
|
||||
|
||||
elput_input_pointer_xy_set(device->em, NULL, x, y);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue