summaryrefslogtreecommitdiff
path: root/src/lib/elput/elput_input.c
diff options
context:
space:
mode:
authorChris Michael <cpmichael@osg.samsung.com>2016-05-10 15:12:53 -0400
committerChris Michael <cpmichael@osg.samsung.com>2016-05-10 15:12:53 -0400
commitfa5abb2967ca1a14770c5270b13200412a0fd345 (patch)
treead02d2cb6699e28359d82d474f6a7974a69cf163 /src/lib/elput/elput_input.c
parent3954aa5518b7cc05f4c8bc86683d349a00dffe47 (diff)
elput: Add API function to set max allowed pointer position
This patch adds an API function that can be used to restrict mouse movement from going outside a screen @feature Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
Diffstat (limited to '')
-rw-r--r--src/lib/elput/elput_input.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/lib/elput/elput_input.c b/src/lib/elput/elput_input.c
index f90b4ed0bd..2dd5607f80 100644
--- a/src/lib/elput/elput_input.c
+++ b/src/lib/elput/elput_input.c
@@ -338,3 +338,20 @@ elput_input_devices_get(Elput_Seat *seat)
338 EINA_SAFETY_ON_NULL_RETURN_VAL(seat, NULL); 338 EINA_SAFETY_ON_NULL_RETURN_VAL(seat, NULL);
339 return seat->devices; 339 return seat->devices;
340} 340}
341
342EAPI void
343elput_input_pointer_max_set(Elput_Manager *manager, int maxw, int maxh)
344{
345 Eina_List *l;
346 Elput_Seat *eseat;
347
348 EINA_SAFETY_ON_NULL_RETURN(manager);
349
350 EINA_LIST_FOREACH(manager->input.seats, l, eseat)
351 {
352 if (!eseat->ptr) continue;
353
354 eseat->ptr->maxw = maxw;
355 eseat->ptr->maxh = maxh;
356 }
357}