Package version up to 0.7.32
[platform/core/api/efl-util.git] / src / efl_util.c
index 6cb96d1..3b94f1f 100644 (file)
@@ -14,6 +14,8 @@
  * limitations under the License.
  */
 
+#define _GNU_SOURCE
+
 #define LOG_TAG "TIZEN_N_EFL_UTIL"
 
 #include <efl_util.h>
@@ -47,6 +49,8 @@
 #define LOG_TAG "TIZEN_N_EFL_UTIL"
 #define EFL_UTIL_INPUT_GENERATOR_TOUCH_MAX_FINGER 10
 
+#define NUM_EVENT_WAIT_DONE_COUNT 10
+
 typedef struct _Efl_Util_Wl_Surface_Lv_Info
 {
    void *surface; /* wl_surface */
@@ -161,7 +165,6 @@ typedef struct _Efl_Util_Data
          int max_touch_count;
          int request_touch_count;
       } devmgr;
-      struct wl_seat *seat;
       struct
       {
          unsigned int id;
@@ -186,6 +189,26 @@ typedef struct _Efl_Util_Data_Default_Queue
          struct tizen_gesture *proto;
          int request_notified;
          int event_init;
+         struct
+         {
+            efl_util_gesture_edge_swipe_cb func;
+            void *data;
+         } edge_swipe_cb;
+         struct
+         {
+            efl_util_gesture_edge_drag_cb func;
+            void *data;
+         } edge_drag_cb;
+         struct
+         {
+            efl_util_gesture_tap_cb func;
+            void *data;
+         } tap_cb;
+         struct
+         {
+            efl_util_gesture_palm_cover_cb func;
+            void *data;
+         } palm_cover_cb;
       } gesture;
    } wl;
 } Efl_Util_Data_Default_Queue;
@@ -199,7 +222,6 @@ static Efl_Util_Data _eflutil =
       { 0, NULL, NULL, NULL }, /* tizen_policy protocol */
       { NULL, NULL, NULL, NULL, 0 }, /* screenshooter protocol */
       { NULL, -1, NULL, NULL, NULL, 0, 0 }, /* tizen_input_device_manager protocol */
-      NULL, /* wl_seat protocol */
       { 0, NULL, NULL } /* display_policy protocol */
    },
 };
@@ -462,22 +484,6 @@ static const struct tizen_screenshooter_listener tz_screenshooter_listener =
 };
 
 static void
-_cb_seat_capabilities(void *data, struct wl_seat *seat, enum wl_seat_capability caps)
-{
-}
-
-static void
-_cb_seat_name(void *data, struct wl_seat *seat EINA_UNUSED, const char *name)
-{
-}
-
-static const struct wl_seat_listener _seat_listener =
-{
-   _cb_seat_capabilities,
-   _cb_seat_name,
-};
-
-static void
 _cb_wl_reg_global(void *data,
                   struct wl_registry *reg,
                   unsigned int id,
@@ -512,11 +518,6 @@ _cb_wl_reg_global(void *data,
         output->output = wl_registry_bind(reg, id, &wl_output_interface, version);
         wl_output_add_listener(output->output, &output_listener, output);
      }
-   else if(strcmp(interface, "wl_seat") == 0)
-     {
-        _eflutil.wl.seat = wl_registry_bind(reg, id, &wl_seat_interface, version);
-        wl_seat_add_listener(_eflutil.wl.seat, &_seat_listener, NULL);
-     }
    else if (strcmp(interface, "tizen_input_device_manager") == 0)
      {
         _eflutil.wl.devmgr.devicemgr = wl_registry_bind(reg, id, &tizen_input_device_manager_interface, version);
@@ -737,6 +738,7 @@ efl_util_set_notification_window_level(Evas_Object *window,
    struct wl_surface *surface;
    Efl_Util_Wl_Surface_Lv_Info *lv_info;
    Ecore_Wl2_Window_Type wl_type;
+   int ret_dispatch = 0;
 
    res = _wl_init();
    EINA_SAFETY_ON_FALSE_RETURN_VAL(res, EFL_UTIL_ERROR_INVALID_PARAMETER);
@@ -752,8 +754,8 @@ efl_util_set_notification_window_level(Evas_Object *window,
                                         EFL_UTIL_ERROR_NOT_SUPPORTED_WINDOW_TYPE);
      }
 
-   while (!_eflutil.wl.policy.proto)
-     wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+   while (!_eflutil.wl.policy.proto && (ret_dispatch != -1))
+     ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
 
    surface = ecore_wl2_window_surface_get(wlwin);
    EINA_SAFETY_ON_NULL_RETURN_VAL(surface,
@@ -790,10 +792,11 @@ efl_util_set_notification_window_level(Evas_Object *window,
    if (lv_info->wait_for_done)
      {
         int count = 0;
-        while (lv_info->wait_for_done && (count < 3))
+        ret_dispatch = 0;
+        while (lv_info->wait_for_done && (count < NUM_EVENT_WAIT_DONE_COUNT) && (ret_dispatch != -1))
           {
              ecore_wl2_display_flush(_eflutil.wl.wl2_display);
-             wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+             ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
              count++;
           }
 
@@ -827,6 +830,7 @@ efl_util_get_notification_window_level(Evas_Object *window,
    struct wl_surface *surface;
    Efl_Util_Wl_Surface_Lv_Info *lv_info;
    Ecore_Wl2_Window_Type wl_type;
+   int ret_dispatch = 0;
 
    res = _wl_init();
    EINA_SAFETY_ON_FALSE_RETURN_VAL(res, EFL_UTIL_ERROR_INVALID_PARAMETER);
@@ -842,8 +846,8 @@ efl_util_get_notification_window_level(Evas_Object *window,
                                         EFL_UTIL_ERROR_NOT_SUPPORTED_WINDOW_TYPE);
      }
 
-   while (!_eflutil.wl.policy.proto)
-     wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+   while (!_eflutil.wl.policy.proto && (ret_dispatch != -1))
+     ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
 
    surface = ecore_wl2_window_surface_get(wlwin);
    EINA_SAFETY_ON_NULL_RETURN_VAL(surface,
@@ -855,10 +859,11 @@ efl_util_get_notification_window_level(Evas_Object *window,
         if (lv_info->wait_for_done)
           {
              int count = 0;
-             while ((lv_info->wait_for_done) && (count < 3))
+             ret_dispatch = 0;
+             while ((lv_info->wait_for_done) && (count < NUM_EVENT_WAIT_DONE_COUNT) && (ret_dispatch != -1))
                {
                   ecore_wl2_display_flush(_eflutil.wl.wl2_display);
-                  wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+                  ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
                   count++;
                }
 
@@ -939,6 +944,7 @@ efl_util_set_window_screen_mode(Evas_Object *window,
    struct wl_surface *surface;
    Efl_Util_Wl_Surface_Scr_Mode_Info *scr_mode_info;
    Eina_Bool res;
+   int ret_dispatch = 0;
 
    res = _wl_init();
    EINA_SAFETY_ON_FALSE_RETURN_VAL(res, EFL_UTIL_ERROR_INVALID_PARAMETER);
@@ -946,8 +952,8 @@ efl_util_set_window_screen_mode(Evas_Object *window,
    wlwin = (Ecore_Wl2_Window *)elm_win_wl_window_get(window);
    if (wlwin)
      {
-        while (!_eflutil.wl.policy.proto)
-          wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+        while (!_eflutil.wl.policy.proto && (ret_dispatch != -1))
+          ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
 
         surface = ecore_wl2_window_surface_get(wlwin);
         EINA_SAFETY_ON_NULL_RETURN_VAL(surface,
@@ -980,10 +986,11 @@ efl_util_set_window_screen_mode(Evas_Object *window,
         if (scr_mode_info->wait_for_done)
           {
              int count = 0;
-             while (scr_mode_info->wait_for_done && (count < 3))
+             ret_dispatch = 0;
+             while (scr_mode_info->wait_for_done && (count < NUM_EVENT_WAIT_DONE_COUNT) && (ret_dispatch != -1))
                {
                   ecore_wl2_display_flush(_eflutil.wl.wl2_display);
-                  wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+                  ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
                   count++;
                }
 
@@ -1017,6 +1024,7 @@ efl_util_get_window_screen_mode(Evas_Object *window,
    struct wl_surface *surface;
    Efl_Util_Wl_Surface_Scr_Mode_Info *scr_mode_info;
    Eina_Bool res;
+   int ret_dispatch = 0;
 
    res = _wl_init();
    EINA_SAFETY_ON_FALSE_RETURN_VAL(res, EFL_UTIL_ERROR_INVALID_PARAMETER);
@@ -1024,8 +1032,8 @@ efl_util_get_window_screen_mode(Evas_Object *window,
    wlwin = (Ecore_Wl2_Window *)elm_win_wl_window_get(window);
    if (wlwin)
      {
-        while (!_eflutil.wl.policy.proto)
-          wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+        while (!_eflutil.wl.policy.proto && (ret_dispatch != -1))
+          ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
 
         surface = ecore_wl2_window_surface_get(wlwin);
         EINA_SAFETY_ON_NULL_RETURN_VAL(surface,
@@ -1036,10 +1044,11 @@ efl_util_get_window_screen_mode(Evas_Object *window,
           {
              if (scr_mode_info->wait_for_done)
                {
-                  while (scr_mode_info->wait_for_done)
+                  ret_dispatch = 0;
+                  while (scr_mode_info->wait_for_done && (ret_dispatch != -1))
                     {
                        ecore_wl2_display_flush(_eflutil.wl.wl2_display);
-                       wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+                       ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
                     }
                }
 
@@ -1069,6 +1078,7 @@ efl_util_set_window_brightness(Evas_Object *window, int brightness)
    struct wl_surface *surface;
    Efl_Util_Wl_Surface_Brightness_Info *brightness_info;
    Eina_Bool res;
+   int ret_dispatch = 0;
 
    EINA_SAFETY_ON_NULL_RETURN_VAL(window, EFL_UTIL_ERROR_INVALID_PARAMETER);
    EINA_SAFETY_ON_FALSE_RETURN_VAL(brightness <= 100, EFL_UTIL_ERROR_INVALID_PARAMETER);
@@ -1079,8 +1089,8 @@ efl_util_set_window_brightness(Evas_Object *window, int brightness)
    wlwin = (Ecore_Wl2_Window *)elm_win_wl_window_get(window);
    if (wlwin)
      {
-        while (!_eflutil.wl.display_policy.proto)
-          wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+        while (!_eflutil.wl.display_policy.proto  && (ret_dispatch != -1))
+          ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
 
         surface = ecore_wl2_window_surface_get(wlwin);
         EINA_SAFETY_ON_NULL_RETURN_VAL(surface,
@@ -1113,10 +1123,11 @@ efl_util_set_window_brightness(Evas_Object *window, int brightness)
          if (brightness_info->wait_for_done)
            {
               int count = 0;
-              while (brightness_info->wait_for_done && (count < 3))
+              ret_dispatch = 0;
+              while (brightness_info->wait_for_done && (count < NUM_EVENT_WAIT_DONE_COUNT) && (ret_dispatch != -1))
                 {
                    ecore_wl2_display_flush(_eflutil.wl.wl2_display);
-                   wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+                   ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
                    count++;
                 }
 
@@ -1145,6 +1156,7 @@ efl_util_get_window_brightness(Evas_Object *window, int *brightness)
    struct wl_surface *surface;
    Efl_Util_Wl_Surface_Brightness_Info *brightness_info;
    Eina_Bool res;
+   int ret_dispatch = 0;
 
    EINA_SAFETY_ON_NULL_RETURN_VAL(window, EFL_UTIL_ERROR_INVALID_PARAMETER);
    EINA_SAFETY_ON_NULL_RETURN_VAL(brightness, EFL_UTIL_ERROR_INVALID_PARAMETER);
@@ -1155,8 +1167,8 @@ efl_util_get_window_brightness(Evas_Object *window, int *brightness)
    wlwin = (Ecore_Wl2_Window *)elm_win_wl_window_get(window);
    if (!wlwin) return EFL_UTIL_ERROR_INVALID_PARAMETER;
 
-   while (!_eflutil.wl.display_policy.proto)
-     wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+   while (!_eflutil.wl.display_policy.proto && (ret_dispatch != -1))
+     ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
 
    surface = ecore_wl2_window_surface_get(wlwin);
    EINA_SAFETY_ON_NULL_RETURN_VAL(surface,
@@ -1167,10 +1179,11 @@ efl_util_get_window_brightness(Evas_Object *window, int *brightness)
      {
         if (brightness_info->wait_for_done)
           {
-             while (brightness_info->wait_for_done)
+             ret_dispatch = 0;
+             while (brightness_info->wait_for_done && (ret_dispatch != -1))
                {
                   ecore_wl2_display_flush(_eflutil.wl.wl2_display);
-                  wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+                  ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
                }
           }
          *brightness = brightness_info->brightness;
@@ -1181,7 +1194,6 @@ efl_util_get_window_brightness(Evas_Object *window, int *brightness)
    return EFL_UTIL_ERROR_NONE;
 }
 
-
 struct _efl_util_inputgen_h
 {
    unsigned int init_type;
@@ -1189,8 +1201,6 @@ struct _efl_util_inputgen_h
    E_Devicemgr_Inputgen_Touch_Axis *axis_info;
 };
 
-/* LCOV_EXCL_STOP */
-
 static void
 _cb_device_add(void *data EINA_UNUSED,
                struct tizen_input_device_manager *tizen_input_device_manager EINA_UNUSED,
@@ -1265,6 +1275,7 @@ _efl_util_input_create_inputgen(unsigned int dev_type, const char *name, int *re
 {
    efl_util_inputgen_h inputgen_h = NULL;
    unsigned int clas = 0x0;
+   int ret_dispatch = 0;
 
    if (!dev_type ||
         dev_type & ~(EFL_UTIL_INPUT_DEVTYPE_TOUCHSCREEN
@@ -1303,8 +1314,8 @@ _efl_util_input_create_inputgen(unsigned int dev_type, const char *name, int *re
    if (dev_type & EFL_UTIL_INPUT_DEVTYPE_POINTER)
      clas |= TIZEN_INPUT_DEVICE_MANAGER_CLAS_MOUSE;
 
-   while (!_eflutil.wl.devmgr.devicemgr)
-     wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+   while (!_eflutil.wl.devmgr.devicemgr && (ret_dispatch != -1))
+     ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
 
    if (with_name == 2)
       tizen_input_device_manager_init_generator_with_sync(_eflutil.wl.devmgr.devicemgr, clas, inputgen_h->name);
@@ -1313,9 +1324,9 @@ _efl_util_input_create_inputgen(unsigned int dev_type, const char *name, int *re
    else
       tizen_input_device_manager_init_generator(_eflutil.wl.devmgr.devicemgr, clas);
 
-
-   while (_eflutil.wl.devmgr.request_notified == -1)
-     wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+   ret_dispatch = 0;
+   while ((_eflutil.wl.devmgr.request_notified == -1) && (ret_dispatch != -1))
+     ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
 
    *ret = _efl_util_input_convert_input_generator_error(_eflutil.wl.devmgr.request_notified);
    _eflutil.wl.devmgr.request_notified = -1;
@@ -1378,6 +1389,7 @@ API int
 efl_util_input_set_touch_count(int max_count)
 {
    int ret = EFL_UTIL_ERROR_NONE;
+   int ret_dispatch = 0;
 
    ret = _wl_init();
    if (ret == (int)EINA_FALSE)
@@ -1385,16 +1397,17 @@ efl_util_input_set_touch_count(int max_count)
         return EFL_UTIL_ERROR_INVALID_PARAMETER;
      }
 
-   while (!_eflutil.wl.devmgr.devicemgr)
-     wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+   while (!_eflutil.wl.devmgr.devicemgr && (ret_dispatch != -1))
+     ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
 
    if (_eflutil.wl.devmgr.max_touch_count >= max_count)
      return EFL_UTIL_ERROR_NONE;
 
    tizen_input_device_manager_set_touch_count(_eflutil.wl.devmgr.devicemgr, max_count);
 
-   while (_eflutil.wl.devmgr.request_notified == -1)
-     wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+   ret_dispatch = 0;
+   while ((_eflutil.wl.devmgr.request_notified == -1) && (ret_dispatch != -1))
+     ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
 
    ret = _efl_util_input_convert_input_generator_error(_eflutil.wl.devmgr.request_notified);
    _eflutil.wl.devmgr.request_notified = -1;
@@ -1412,6 +1425,7 @@ efl_util_input_deinitialize_generator(efl_util_inputgen_h inputgen_h)
 {
    int ret = EFL_UTIL_ERROR_NONE;
    unsigned int clas = 0x0;
+   int ret_dispatch = 0;
    EINA_SAFETY_ON_NULL_RETURN_VAL(inputgen_h, EFL_UTIL_ERROR_INVALID_PARAMETER);
 
    if (inputgen_h->init_type & EFL_UTIL_INPUT_DEVTYPE_TOUCHSCREEN)
@@ -1431,8 +1445,8 @@ efl_util_input_deinitialize_generator(efl_util_inputgen_h inputgen_h)
 
    tizen_input_device_manager_deinit_generator(_eflutil.wl.devmgr.devicemgr, clas);
 
-   while (_eflutil.wl.devmgr.request_notified == -1)
-     wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+   while ((_eflutil.wl.devmgr.request_notified == -1) && (ret_dispatch != -1))
+     ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
 
    ret = _efl_util_input_convert_input_generator_error(_eflutil.wl.devmgr.request_notified);
    _eflutil.wl.devmgr.request_notified = -1;
@@ -1444,6 +1458,7 @@ API int
 efl_util_input_generate_key(efl_util_inputgen_h inputgen_h, const char *key_name, int pressed)
 {
    int ret = EFL_UTIL_ERROR_NONE;
+   int ret_dispatch = 0;
 
    EINA_SAFETY_ON_NULL_RETURN_VAL(inputgen_h, EFL_UTIL_ERROR_INVALID_PARAMETER);
    EINA_SAFETY_ON_NULL_RETURN_VAL(key_name, EFL_UTIL_ERROR_INVALID_PARAMETER);
@@ -1454,8 +1469,8 @@ efl_util_input_generate_key(efl_util_inputgen_h inputgen_h, const char *key_name
 
    tizen_input_device_manager_generate_key(_eflutil.wl.devmgr.devicemgr, key_name, pressed);
 
-   while (_eflutil.wl.devmgr.request_notified == -1)
-     wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+   while ((_eflutil.wl.devmgr.request_notified == -1) && (ret_dispatch != -1))
+     ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
 
    ret = _efl_util_input_convert_input_generator_error(_eflutil.wl.devmgr.request_notified);
    _eflutil.wl.devmgr.request_notified = -1;
@@ -1468,6 +1483,7 @@ efl_util_input_generate_touch(efl_util_inputgen_h inputgen_h, int idx,
                               efl_util_input_touch_type_e touch_type, int x, int y)
 {
    int ret;
+   int ret_dispatch = 0;
    enum tizen_input_device_manager_pointer_event_type type;
 
    EINA_SAFETY_ON_NULL_RETURN_VAL(inputgen_h, EFL_UTIL_ERROR_INVALID_PARAMETER);
@@ -1475,6 +1491,10 @@ efl_util_input_generate_touch(efl_util_inputgen_h inputgen_h, int idx,
    EINA_SAFETY_ON_FALSE_RETURN_VAL((x > 0 && y > 0), EFL_UTIL_ERROR_INVALID_PARAMETER);
    EINA_SAFETY_ON_FALSE_RETURN_VAL(inputgen_h->init_type & EFL_UTIL_INPUT_DEVTYPE_TOUCHSCREEN, EFL_UTIL_ERROR_NO_SUCH_DEVICE);
 
+   if (_eflutil.wl.devmgr.request_touch_count != 0 &&
+       _eflutil.wl.devmgr.max_touch_count != _eflutil.wl.devmgr.request_touch_count)
+     ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+
    if (idx >= _eflutil.wl.devmgr.max_touch_count)
      return EFL_UTIL_ERROR_INVALID_PARAMETER;
 
@@ -1497,8 +1517,8 @@ efl_util_input_generate_touch(efl_util_inputgen_h inputgen_h, int idx,
 
    tizen_input_device_manager_generate_touch(_eflutil.wl.devmgr.devicemgr, type, x, y, idx);
 
-   while (_eflutil.wl.devmgr.request_notified == -1)
-     wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+   while ((_eflutil.wl.devmgr.request_notified == -1) && (ret_dispatch != -1))
+     ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
 
    ret = _efl_util_input_convert_input_generator_error(_eflutil.wl.devmgr.request_notified);
    _eflutil.wl.devmgr.request_notified = -1;
@@ -1510,11 +1530,12 @@ static int
 _efl_util_input_generate_touch_axis_send(unsigned int type, double value)
 {
    int ret;
+   int ret_dispatch = 0;
 
    tizen_input_device_manager_generate_axis(_eflutil.wl.devmgr.devicemgr, type, wl_fixed_from_double(value));
 
-   while (_eflutil.wl.devmgr.request_notified == -1)
-     wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+   while ((_eflutil.wl.devmgr.request_notified == -1) && (ret_dispatch != -1))
+     ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
 
    ret = _efl_util_input_convert_input_generator_error(_eflutil.wl.devmgr.request_notified);
    _eflutil.wl.devmgr.request_notified = -1;
@@ -1601,6 +1622,7 @@ efl_util_input_generate_touch_axis(efl_util_inputgen_h inputgen_h, int idx,
                                    double pressure, double angle, double palm)
 {
    int ret, version;
+   int ret_dispatch = 0;
    enum tizen_input_device_manager_pointer_event_type type;
 
    EINA_SAFETY_ON_NULL_RETURN_VAL(inputgen_h, EFL_UTIL_ERROR_INVALID_PARAMETER);
@@ -1636,8 +1658,8 @@ efl_util_input_generate_touch_axis(efl_util_inputgen_h inputgen_h, int idx,
 
    tizen_input_device_manager_generate_touch(_eflutil.wl.devmgr.devicemgr, type, x, y, idx);
 
-   while (_eflutil.wl.devmgr.request_notified == -1)
-     wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+   while ((_eflutil.wl.devmgr.request_notified == -1) && (ret_dispatch != -1))
+     ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
 
    ret = _efl_util_input_convert_input_generator_error(_eflutil.wl.devmgr.request_notified);
    _eflutil.wl.devmgr.request_notified = -1;
@@ -1650,6 +1672,7 @@ API int
 efl_util_input_generate_pointer(efl_util_inputgen_h inputgen_h, int buttons, efl_util_input_pointer_type_e pointer_type, int x, int y)
 {
    int ret;
+   int ret_dispatch = 0;
    enum tizen_input_device_manager_pointer_event_type type;
 
    EINA_SAFETY_ON_NULL_RETURN_VAL(inputgen_h, EFL_UTIL_ERROR_INVALID_PARAMETER);
@@ -1676,8 +1699,8 @@ efl_util_input_generate_pointer(efl_util_inputgen_h inputgen_h, int buttons, efl
 
    tizen_input_device_manager_generate_pointer(_eflutil.wl.devmgr.devicemgr, type, x, y, buttons);
 
-   while (_eflutil.wl.devmgr.request_notified == -1)
-     wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+   while ((_eflutil.wl.devmgr.request_notified == -1) && (ret_dispatch != -1))
+     ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
 
    ret = _efl_util_input_convert_input_generator_error(_eflutil.wl.devmgr.request_notified);
    _eflutil.wl.devmgr.request_notified = -1;
@@ -1689,6 +1712,7 @@ API int
 efl_util_input_generate_wheel(efl_util_inputgen_h inputgen_h, efl_util_input_pointer_wheel_type_e wheel_type, int value)
 {
    int ret, version;
+   int ret_dispatch = 0;
    enum tizen_input_device_manager_pointer_event_type type;
 
    EINA_SAFETY_ON_NULL_RETURN_VAL(inputgen_h, EFL_UTIL_ERROR_INVALID_PARAMETER);
@@ -1712,8 +1736,8 @@ efl_util_input_generate_wheel(efl_util_inputgen_h inputgen_h, efl_util_input_poi
 
    tizen_input_device_manager_generate_axis(_eflutil.wl.devmgr.devicemgr, type, wl_fixed_from_int(value));
 
-   while (_eflutil.wl.devmgr.request_notified == -1)
-     wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
+   while ((_eflutil.wl.devmgr.request_notified == -1) && (ret_dispatch != -1))
+     ret_dispatch = wl_display_dispatch_queue(_eflutil.wl.dpy, _eflutil.wl.queue);
 
    ret = _efl_util_input_convert_input_generator_error(_eflutil.wl.devmgr.request_notified);
    _eflutil.wl.devmgr.request_notified = -1;
@@ -2428,7 +2452,13 @@ efl_util_screenmirror_start(efl_util_screenmirror_h screenmirror)
 
    ret = pthread_create(&screenmirror->thread, NULL, _efl_util_screenmirror_loop, screenmirror);
    if (ret < 0)
-     fprintf(stderr, "[screenmirror] fail: thread create fail\n");
+     {
+        fprintf(stderr, "[screenmirror] fail: thread create fail\n");
+        _screenshot_mutex_unlock();
+        return EFL_UTIL_ERROR_SCREENSHOT_EXECUTION_FAIL;
+     }
+
+   pthread_setname_np(screenmirror->thread, "e_util_mirror");
 
    _screenshot_mutex_unlock();
 
@@ -2486,12 +2516,14 @@ API int EFL_UTIL_EVENT_GESTURE_PALM_COVER = 0;
 static void
 _cb_gesture_edge_swipe_notify(void *data EINA_UNUSED, struct tizen_gesture *tizen_gesture EINA_UNUSED, uint32_t fingers EINA_UNUSED, uint32_t edge EINA_UNUSED, uint32_t edge_size EINA_UNUSED, uint32_t start_point EINA_UNUSED, uint32_t end_point EINA_UNUSED, uint32_t error)
 {
+   LOGD("");
    _eflutil_defaultqueue.wl.gesture.request_notified = error;
 }
 
 static void
 _cb_gesture_edge_swipe(void *data EINA_UNUSED, struct tizen_gesture *tizen_gesture EINA_UNUSED, uint32_t mode, uint32_t fingers, int sx, int sy, uint32_t edge)
 {
+   LOGD("");
    efl_util_event_gesture_edge_swipe_s *ev = NULL;
 
    ev = (efl_util_event_gesture_edge_swipe_s *)calloc(1, sizeof(*ev));
@@ -2505,17 +2537,22 @@ _cb_gesture_edge_swipe(void *data EINA_UNUSED, struct tizen_gesture *tizen_gestu
    ev->edge = edge;
 
    ecore_event_add(EFL_UTIL_EVENT_GESTURE_EDGE_SWIPE, ev, NULL, NULL);
+
+   if (_eflutil_defaultqueue.wl.gesture.edge_swipe_cb.func)
+     _eflutil_defaultqueue.wl.gesture.edge_swipe_cb.func(_eflutil_defaultqueue.wl.gesture.edge_swipe_cb.data, mode, fingers, sx, sy, edge);
 }
 
 static void
 _cb_gesture_edge_drag_notify(void *data EINA_UNUSED, struct tizen_gesture *tizen_gesture EINA_UNUSED, uint32_t fingers EINA_UNUSED, uint32_t edge EINA_UNUSED, uint32_t edge_size EINA_UNUSED, uint32_t start_point EINA_UNUSED, uint32_t end_point EINA_UNUSED, uint32_t error)
 {
+   LOGD("");
    _eflutil_defaultqueue.wl.gesture.request_notified = error;
 }
 
 static void
 _cb_gesture_edge_drag(void *data EINA_UNUSED, struct tizen_gesture *tizen_gesture EINA_UNUSED, uint32_t mode, uint32_t fingers, int cx, int cy, uint32_t edge)
 {
+   LOGD("");
    efl_util_event_gesture_edge_drag_s *ev = NULL;
 
    ev = (efl_util_event_gesture_edge_drag_s *)calloc(1, sizeof(*ev));
@@ -2529,17 +2566,22 @@ _cb_gesture_edge_drag(void *data EINA_UNUSED, struct tizen_gesture *tizen_gestur
    ev->edge = edge;
 
    ecore_event_add(EFL_UTIL_EVENT_GESTURE_EDGE_DRAG, ev, NULL, NULL);
+
+   if (_eflutil_defaultqueue.wl.gesture.edge_drag_cb.func)
+     _eflutil_defaultqueue.wl.gesture.edge_drag_cb.func(_eflutil_defaultqueue.wl.gesture.edge_drag_cb.data, mode, fingers, cx, cy, edge);
 }
 
 static void
 _cb_gesture_tap_notify(void *data EINA_UNUSED, struct tizen_gesture *tizen_gesture EINA_UNUSED, uint32_t fingers EINA_UNUSED, uint32_t repeat EINA_UNUSED, uint32_t error)
 {
+   LOGD("");
    _eflutil_defaultqueue.wl.gesture.request_notified = error;
 }
 
 static void
 _cb_gesture_tap(void *data EINA_UNUSED, struct tizen_gesture *tizen_gesture EINA_UNUSED, uint32_t mode, uint32_t fingers, uint32_t repeats)
 {
+   LOGD("");
    efl_util_event_gesture_tap_s *ev = NULL;
 
    ev = (efl_util_event_gesture_tap_s *)calloc(1, sizeof(*ev));
@@ -2551,12 +2593,16 @@ _cb_gesture_tap(void *data EINA_UNUSED, struct tizen_gesture *tizen_gesture EINA
    ev->repeats = repeats;
 
    ecore_event_add(EFL_UTIL_EVENT_GESTURE_TAP, ev, NULL, NULL);
+
+   if (_eflutil_defaultqueue.wl.gesture.tap_cb.func)
+     _eflutil_defaultqueue.wl.gesture.tap_cb.func(_eflutil_defaultqueue.wl.gesture.tap_cb.data, mode, fingers, repeats);
 }
 /* LCOV_EXCL_STOP */
 
 static void
 _cb_gesture_palm_cover_notify(void *data EINA_UNUSED, struct tizen_gesture *tizen_gesture EINA_UNUSED, struct wl_surface *surface EINA_UNUSED, uint32_t error)
 {
+   LOGD("");
    _eflutil_defaultqueue.wl.gesture.request_notified = error;
 }
 
@@ -2564,6 +2610,7 @@ _cb_gesture_palm_cover_notify(void *data EINA_UNUSED, struct tizen_gesture *tize
 static void
 _cb_gesture_palm_cover(void *data EINA_UNUSED, struct tizen_gesture *tizen_gesture EINA_UNUSED, struct wl_surface *surface, uint32_t mode, uint32_t duration, int cx, int cy, uint32_t size, wl_fixed_t pressure)
 {
+   LOGD("");
    efl_util_event_gesture_palm_cover_s *ev = NULL;
 
    ev = (efl_util_event_gesture_palm_cover_s *)calloc(1, sizeof(*ev));
@@ -2578,12 +2625,16 @@ _cb_gesture_palm_cover(void *data EINA_UNUSED, struct tizen_gesture *tizen_gestu
    ev->pressure = wl_fixed_to_int(pressure);
 
    ecore_event_add(EFL_UTIL_EVENT_GESTURE_PALM_COVER, ev, NULL, NULL);
+
+   if (_eflutil_defaultqueue.wl.gesture.palm_cover_cb.func)
+     _eflutil_defaultqueue.wl.gesture.palm_cover_cb.func(_eflutil_defaultqueue.wl.gesture.palm_cover_cb.data, mode, duration, cx, cy, size, pressure);
 }
 /* LCOV_EXCL_STOP */
 
 static void
 _cb_gesture_activate_notify(void *data EINA_UNUSED, struct tizen_gesture *tizen_gesture EINA_UNUSED, struct wl_surface *surface EINA_UNUSED, uint32_t type EINA_UNUSED, uint32_t active EINA_UNUSED, uint32_t error)
 {
+   LOGD("");
    _eflutil_defaultqueue.wl.gesture.request_notified = error;
 }
 
@@ -2627,6 +2678,7 @@ _efl_util_gesture_verify_request_notified()
 static int
 _efl_util_gesture_grab_edge_swipe(efl_util_gesture_data data, Eina_Bool grabbed)
 {
+   LOGD("");
    int ret = EFL_UTIL_ERROR_NONE;
    Efl_Util_Gesture_Common_Grab_Data *base_data = NULL;
    Efl_Util_Gesture_Edge_Swipe_Grab_Data *edge_swipe_data = NULL;
@@ -2664,6 +2716,7 @@ _efl_util_gesture_grab_edge_swipe(efl_util_gesture_data data, Eina_Bool grabbed)
 static int
 _efl_util_gesture_grab_edge_drag(efl_util_gesture_data data, Eina_Bool grabbed)
 {
+   LOGD("");
    int ret = EFL_UTIL_ERROR_NONE;
    Efl_Util_Gesture_Common_Grab_Data *base_data = NULL;
    Efl_Util_Gesture_Edge_Drag_Grab_Data *edge_drag_data = NULL;
@@ -2701,6 +2754,7 @@ _efl_util_gesture_grab_edge_drag(efl_util_gesture_data data, Eina_Bool grabbed)
 static int
 _efl_util_gesture_grab_tap(efl_util_gesture_data data, Eina_Bool grabbed)
 {
+   LOGD("");
    int ret = EFL_UTIL_ERROR_NONE;
    Efl_Util_Gesture_Common_Grab_Data *base_data = NULL;
    Efl_Util_Gesture_Tap_Grab_Data *tap_data = NULL;
@@ -2732,6 +2786,7 @@ _efl_util_gesture_grab_tap(efl_util_gesture_data data, Eina_Bool grabbed)
 static int
 _efl_util_gesture_grab_palm_cover(efl_util_gesture_data data, Eina_Bool grabbed)
 {
+   LOGD("");
    int ret = EFL_UTIL_ERROR_NONE;
    Efl_Util_Gesture_Common_Grab_Data *base_data = NULL;
 
@@ -2756,6 +2811,7 @@ _efl_util_gesture_grab_palm_cover(efl_util_gesture_data data, Eina_Bool grabbed)
 API efl_util_gesture_h
 efl_util_gesture_initialize(void)
 {
+   LOGD("");
    efl_util_gesture_h gesture_h = NULL;
 
    gesture_h = (efl_util_gesture_h)calloc(1, sizeof(struct _efl_util_gesture_h));
@@ -2806,6 +2862,7 @@ out:
 API int
 efl_util_gesture_deinitialize(efl_util_gesture_h gesture_h)
 {
+   LOGD("");
    EINA_SAFETY_ON_NULL_RETURN_VAL(gesture_h, EFL_UTIL_ERROR_INVALID_PARAMETER);
    EINA_SAFETY_ON_FALSE_RETURN_VAL(gesture_h->init, EFL_UTIL_ERROR_INVALID_PARAMETER);
 
@@ -2830,6 +2887,7 @@ efl_util_gesture_deinitialize(efl_util_gesture_h gesture_h)
 API efl_util_gesture_data
 efl_util_gesture_edge_swipe_new(efl_util_gesture_h gesture_h, unsigned int fingers, efl_util_gesture_edge_e edge)
 {
+   LOGD("");
    Efl_Util_Gesture_Edge_Swipe_Grab_Data *data;
 
    if (!gesture_h || gesture_h->init == EINA_FALSE)
@@ -2864,6 +2922,7 @@ efl_util_gesture_edge_swipe_new(efl_util_gesture_h gesture_h, unsigned int finge
 API int
 efl_util_gesture_edge_swipe_free(efl_util_gesture_h gesture_h, efl_util_gesture_data data)
 {
+   LOGD("");
    if (!gesture_h || gesture_h->init == EINA_FALSE)
      {
         return EFL_UTIL_ERROR_INVALID_PARAMETER;
@@ -2883,6 +2942,7 @@ efl_util_gesture_edge_swipe_free(efl_util_gesture_h gesture_h, efl_util_gesture_
 API int
 efl_util_gesture_edge_swipe_size_set(efl_util_gesture_data data, efl_util_gesture_edge_size_e edge_size, unsigned int start_point, unsigned int end_point)
 {
+   LOGD("");
    Efl_Util_Gesture_Edge_Swipe_Grab_Data *edge_swipe_data = data;
 
    EINA_SAFETY_ON_NULL_RETURN_VAL(edge_swipe_data, EFL_UTIL_ERROR_INVALID_PARAMETER);
@@ -2902,6 +2962,7 @@ efl_util_gesture_edge_swipe_size_set(efl_util_gesture_data data, efl_util_gestur
 API efl_util_gesture_data
 efl_util_gesture_edge_drag_new(efl_util_gesture_h gesture_h, unsigned int fingers, efl_util_gesture_edge_e edge)
 {
+   LOGD("");
    Efl_Util_Gesture_Edge_Drag_Grab_Data *data;
 
    if (!gesture_h || gesture_h->init == EINA_FALSE)
@@ -2936,6 +2997,7 @@ efl_util_gesture_edge_drag_new(efl_util_gesture_h gesture_h, unsigned int finger
 API int
 efl_util_gesture_edge_drag_free(efl_util_gesture_h gesture_h, efl_util_gesture_data data)
 {
+   LOGD("");
    if (!gesture_h || gesture_h->init == EINA_FALSE)
      {
         return EFL_UTIL_ERROR_INVALID_PARAMETER;
@@ -2955,6 +3017,7 @@ efl_util_gesture_edge_drag_free(efl_util_gesture_h gesture_h, efl_util_gesture_d
 API int
 efl_util_gesture_edge_drag_size_set(efl_util_gesture_data data, efl_util_gesture_edge_size_e edge_size, unsigned int start_point, unsigned int end_point)
 {
+   LOGD("");
    Efl_Util_Gesture_Edge_Drag_Grab_Data *edge_drag_data = data;
 
    EINA_SAFETY_ON_NULL_RETURN_VAL(edge_drag_data, EFL_UTIL_ERROR_INVALID_PARAMETER);
@@ -2974,6 +3037,7 @@ efl_util_gesture_edge_drag_size_set(efl_util_gesture_data data, efl_util_gesture
 API efl_util_gesture_data
 efl_util_gesture_tap_new(efl_util_gesture_h gesture_h, unsigned int fingers, unsigned int repeats)
 {
+   LOGD("");
    Efl_Util_Gesture_Tap_Grab_Data *data;
 
    if (!gesture_h || gesture_h->init == EINA_FALSE)
@@ -3007,6 +3071,7 @@ efl_util_gesture_tap_new(efl_util_gesture_h gesture_h, unsigned int fingers, uns
 API int
 efl_util_gesture_tap_free(efl_util_gesture_h gesture_h, efl_util_gesture_data data)
 {
+   LOGD("");
    if (!gesture_h || gesture_h->init == EINA_FALSE)
      {
         return EFL_UTIL_ERROR_INVALID_PARAMETER;
@@ -3026,6 +3091,7 @@ efl_util_gesture_tap_free(efl_util_gesture_h gesture_h, efl_util_gesture_data da
 API efl_util_gesture_data
 efl_util_gesture_palm_cover_new(efl_util_gesture_h gesture_h)
 {
+   LOGD("");
    Efl_Util_Gesture_Palm_Cover_Grab_Data *data;
 
    if (!gesture_h || gesture_h->init == EINA_FALSE)
@@ -3051,6 +3117,7 @@ efl_util_gesture_palm_cover_new(efl_util_gesture_h gesture_h)
 API int
 efl_util_gesture_palm_cover_free(efl_util_gesture_h gesture_h, efl_util_gesture_data data)
 {
+   LOGD("");
    if (!gesture_h || gesture_h->init == EINA_FALSE)
      {
         return EFL_UTIL_ERROR_INVALID_PARAMETER;
@@ -3071,6 +3138,7 @@ efl_util_gesture_palm_cover_free(efl_util_gesture_h gesture_h, efl_util_gesture_
 API int
 efl_util_gesture_grab(efl_util_gesture_h gesture_h, efl_util_gesture_data data)
 {
+   LOGD("");
    int ret = EFL_UTIL_ERROR_NONE;
    Efl_Util_Gesture_Common_Grab_Data *base_data = NULL;
 
@@ -3104,6 +3172,7 @@ efl_util_gesture_grab(efl_util_gesture_h gesture_h, efl_util_gesture_data data)
 API int
 efl_util_gesture_ungrab(efl_util_gesture_h gesture_h, efl_util_gesture_data data)
 {
+   LOGD("");
    int ret = EFL_UTIL_ERROR_NONE;
    Efl_Util_Gesture_Common_Grab_Data *base_data = NULL;
 
@@ -3138,6 +3207,7 @@ efl_util_gesture_ungrab(efl_util_gesture_h gesture_h, efl_util_gesture_data data
 API int
 efl_util_gesture_select(efl_util_gesture_h gesture_h, Evas_Object *window, efl_util_gesture_data data)
 {
+   LOGD("");
    Efl_Util_Gesture_Common_Grab_Data *base_data = NULL;
    Ecore_Wl2_Window *wlwin;
    struct wl_surface *surface;
@@ -3170,6 +3240,7 @@ efl_util_gesture_select(efl_util_gesture_h gesture_h, Evas_Object *window, efl_u
 API int
 efl_util_gesture_deselect(efl_util_gesture_h gesture_h, Evas_Object *window, efl_util_gesture_data data)
 {
+   LOGD("");
    Efl_Util_Gesture_Common_Grab_Data *base_data = NULL;
    Ecore_Wl2_Window *wlwin;
    struct wl_surface *surface;
@@ -3203,6 +3274,7 @@ efl_util_gesture_deselect(efl_util_gesture_h gesture_h, Evas_Object *window, efl
 API int
 efl_util_gesture_activate_set(efl_util_gesture_h gesture_h, unsigned int type, Eina_Bool active)
 {
+   LOGD("");
    int ret;
 
    EINA_SAFETY_ON_NULL_RETURN_VAL(gesture_h, EFL_UTIL_ERROR_INVALID_PARAMETER);
@@ -3220,6 +3292,7 @@ efl_util_gesture_activate_set(efl_util_gesture_h gesture_h, unsigned int type, E
 API int
 efl_util_gesture_activate_set_on_window(efl_util_gesture_h gesture_h, Evas_Object *window, unsigned int type, Eina_Bool active)
 {
+   LOGD("");
    Ecore_Wl2_Window *wlwin;
    struct wl_surface *surface;
    int ret;
@@ -3242,3 +3315,59 @@ efl_util_gesture_activate_set_on_window(efl_util_gesture_h gesture_h, Evas_Objec
 
    return ret;
 }
+
+API int efl_util_gesture_edge_swipe_cb_set(efl_util_gesture_h gesture_h, efl_util_gesture_edge_swipe_cb cb_func, void *data)
+{
+   LOGD("");
+   int ret = EFL_UTIL_ERROR_NONE;
+
+   EINA_SAFETY_ON_NULL_RETURN_VAL(gesture_h, EFL_UTIL_ERROR_INVALID_PARAMETER);
+   EINA_SAFETY_ON_FALSE_RETURN_VAL(gesture_h->init, EFL_UTIL_ERROR_INVALID_PARAMETER);
+
+   _eflutil_defaultqueue.wl.gesture.edge_swipe_cb.func = cb_func;
+   _eflutil_defaultqueue.wl.gesture.edge_swipe_cb.data = data;
+
+   return ret;
+}
+
+API int efl_util_gesture_edge_drag_cb_set(efl_util_gesture_h gesture_h, efl_util_gesture_edge_drag_cb cb_func, void *data)
+{
+   LOGD("");
+   int ret = EFL_UTIL_ERROR_NONE;
+
+   EINA_SAFETY_ON_NULL_RETURN_VAL(gesture_h, EFL_UTIL_ERROR_INVALID_PARAMETER);
+   EINA_SAFETY_ON_FALSE_RETURN_VAL(gesture_h->init, EFL_UTIL_ERROR_INVALID_PARAMETER);
+
+   _eflutil_defaultqueue.wl.gesture.edge_drag_cb.func = cb_func;
+   _eflutil_defaultqueue.wl.gesture.edge_drag_cb.data = data;
+
+   return ret;
+}
+
+API int efl_util_gesture_tap_cb_set(efl_util_gesture_h gesture_h, efl_util_gesture_tap_cb cb_func, void *data)
+{
+   LOGD("");
+   int ret = EFL_UTIL_ERROR_NONE;
+
+   EINA_SAFETY_ON_NULL_RETURN_VAL(gesture_h, EFL_UTIL_ERROR_INVALID_PARAMETER);
+   EINA_SAFETY_ON_FALSE_RETURN_VAL(gesture_h->init, EFL_UTIL_ERROR_INVALID_PARAMETER);
+
+   _eflutil_defaultqueue.wl.gesture.tap_cb.func = cb_func;
+   _eflutil_defaultqueue.wl.gesture.tap_cb.data = data;
+
+   return ret;
+}
+
+API int efl_util_gesture_palm_cover_cb_set(efl_util_gesture_h gesture_h, efl_util_gesture_palm_cover_cb cb_func, void *data)
+{
+   LOGD("");
+   int ret = EFL_UTIL_ERROR_NONE;
+
+   EINA_SAFETY_ON_NULL_RETURN_VAL(gesture_h, EFL_UTIL_ERROR_INVALID_PARAMETER);
+   EINA_SAFETY_ON_FALSE_RETURN_VAL(gesture_h->init, EFL_UTIL_ERROR_INVALID_PARAMETER);
+
+   _eflutil_defaultqueue.wl.gesture.palm_cover_cb.func = cb_func;
+   _eflutil_defaultqueue.wl.gesture.palm_cover_cb.data = data;
+
+   return ret;
+}