devilhorns pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=b43f6c14ddfd39bc8402e62ba6eb4f58436266f4

commit b43f6c14ddfd39bc8402e62ba6eb4f58436266f4
Author: Chris Michael <[email protected]>
Date:   Thu Aug 24 11:32:51 2017 -0400

    ecore-drm2: Add API function to allow setting pointer acceleration speed
    
    Small patch to add a new API function which can be called from
    Enlightenment in order to allow setting pointer acceleration speed.
    
    ref T4736
    
    @feature
    
    Signed-off-by: Chris Michael <[email protected]>
---
 src/lib/ecore_drm2/Ecore_Drm2.h        | 11 +++++++++++
 src/lib/ecore_drm2/ecore_drm2_device.c |  8 ++++++++
 2 files changed, 19 insertions(+)

diff --git a/src/lib/ecore_drm2/Ecore_Drm2.h b/src/lib/ecore_drm2/Ecore_Drm2.h
index e1609adac2..f9055fb927 100644
--- a/src/lib/ecore_drm2/Ecore_Drm2.h
+++ b/src/lib/ecore_drm2/Ecore_Drm2.h
@@ -273,6 +273,17 @@ EAPI void ecore_drm2_device_window_set(Ecore_Drm2_Device 
*device, unsigned int w
 EAPI void ecore_drm2_device_pointer_max_set(Ecore_Drm2_Device *device, int w, 
int h);
 
 /**
+ * Set pointer acceleration speed
+ *
+ * @param device
+ * @param speed
+ *
+ * @ingroup Ecore_Drm2_Device_Group
+ * @since 1.21
+ */
+EAPI void ecore_drm2_device_pointer_accel_speed_set(Ecore_Drm2_Device *device, 
double speed);
+
+/**
  * Set pointer value rotation
  *
  * @param device
diff --git a/src/lib/ecore_drm2/ecore_drm2_device.c 
b/src/lib/ecore_drm2/ecore_drm2_device.c
index e5a41fd9c8..0c633b95c4 100644
--- a/src/lib/ecore_drm2/ecore_drm2_device.c
+++ b/src/lib/ecore_drm2/ecore_drm2_device.c
@@ -775,6 +775,14 @@ ecore_drm2_device_pointer_rotation_set(Ecore_Drm2_Device 
*device, int rotation)
 }
 
 EAPI void
+ecore_drm2_device_pointer_accel_speed_set(Ecore_Drm2_Device *device, double 
speed)
+{
+   EINA_SAFETY_ON_NULL_RETURN(device);
+
+   elput_input_pointer_accel_speed_set(device->em, NULL, speed);
+}
+
+EAPI void
 ecore_drm2_device_window_set(Ecore_Drm2_Device *device, unsigned int window)
 {
    EINA_SAFETY_ON_NULL_RETURN(device);

-- 


Reply via email to