From: Chris Michael Date: Tue, 10 May 2016 17:49:38 +0000 (-0400) Subject: elput: Add API function to return a list of Elput_Devices on a given X-Git-Tag: upstream/1.20.0~6402 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=be763a011c4d37edff48d8db99bf234514670cb6;p=platform%2Fupstream%2Fefl.git elput: Add API function to return a list of Elput_Devices on a given seat This patch adds a new API function which can be called to retrieve a list of existing Elput_Devices on a given Elput_Seat. @feature Signed-off-by: Chris Michael --- diff --git a/src/lib/elput/Elput.h b/src/lib/elput/Elput.h index 98d81d7..87d3462 100644 --- a/src/lib/elput/Elput.h +++ b/src/lib/elput/Elput.h @@ -286,6 +286,18 @@ EAPI void elput_input_pointer_xy_get(Elput_Manager *manager, const char *seat, i EAPI void elput_input_pointer_xy_set(Elput_Manager *manager, const char *seat, int x, int y); /** + * Get the list of devices on a given seat + * + * @param seat + * + * @return An Eina_List of existing Elput_Devices on a given seat or NULL on failure + * + * @ingroup Elput_Input_Group + * @since 1.18 + */ +EAPI const Eina_List *elput_input_devices_get(Elput_Seat *seat); + +/** * @defgroup Elput_Device_Group * * Functions that deal with input devices. diff --git a/src/lib/elput/elput_input.c b/src/lib/elput/elput_input.c index 8a15694..11269df 100644 --- a/src/lib/elput/elput_input.c +++ b/src/lib/elput/elput_input.c @@ -328,3 +328,10 @@ elput_input_pointer_xy_set(Elput_Manager *manager, const char *seat, int x, int } } } + +EAPI const Eina_List * +elput_input_devices_get(Elput_Seat *seat) +{ + EINA_SAFETY_ON_NULL_RETURN_VAL(seat, NULL); + return seat->devices; +}