#include "e_mod_main.h"
void
-_e_gesture_conf_value_check(E_Gesture_Config_Data* gconfig)
+_e_gesture_conf_edge_swipe_check(E_Gesture_Conf_Edd *conf)
{
- E_Gesture_Conf_Edd *conf;
- if (!gconfig->conf) gconfig->conf = E_NEW(E_Gesture_Conf_Edd, 1);
- EINA_SAFETY_ON_NULL_RETURN(gconfig->conf);
-
- conf = gconfig->conf;
-
if (!conf->key_device_name) conf->key_device_name = strdup(E_GESTURE_KEYBOARD_DEVICE);
if (conf->edge_swipe.time_done <= 0.0) conf->edge_swipe.time_done = E_GESTURE_EDGE_SWIPE_DONE_TIME;
if (conf->edge_swipe.time_begin <= 0.0) conf->edge_swipe.time_begin = E_GESTURE_EDGE_SWIPE_START_TIME;
if (conf->edge_swipe.max_length <= 0) conf->edge_swipe.max_length = E_GESTURE_EDGE_SWIPE_DIFF_SUCCESS;
if (conf->edge_swipe.compose_key <= 0) conf->edge_swipe.compose_key = E_GESTURE_EDGE_SWIPE_COMBINE_KEY;
if (conf->edge_swipe.back_key <= 0) conf->edge_swipe.back_key = E_GESTURE_EDGE_SWIPE_BACK_KEY;
+}
+void
+_e_gesture_conf_edge_drag_check(E_Gesture_Conf_Edd *conf)
+{
if (conf->edge_drag.time_begin <= 0.0) conf->edge_drag.time_begin = E_GESTURE_EDGE_DRAG_START_TIME;
if (conf->edge_drag.area_offset <= 0) conf->edge_drag.area_offset = E_GESTURE_EDGE_DRAG_START_AREA;
if (conf->edge_drag.diff_length <= 0) conf->edge_drag.diff_length = E_GESTURE_EDGE_DRAG_DIFF;
+}
+void
+_e_gesture_conf_tap_check(E_Gesture_Conf_Edd *conf)
+{
if (conf->tap.repeats_max <= 0) conf->tap.repeats_max = E_GESTURE_TAP_REPEATS_MAX;
if (conf->tap.time_start <= 0.0) conf->tap.time_start = E_GESTURE_TAP_START_TIME;
if (conf->tap.time_done <= 0.0) conf->tap.time_done = E_GESTURE_TAP_DONE_TIME;
if (conf->tap.time_interval <= 0.0) conf->tap.time_interval = E_GESTURE_TAP_INTERVAL_TIME;
if (conf->tap.moving_range <= 0) conf->tap.moving_range = E_GESTURE_TAP_MOVING_RANGE;
+}
+void
+_e_gesture_conf_pan_check(E_Gesture_Conf_Edd *conf)
+{
if (conf->pan.time_start <= 0.0) conf->pan.time_start = E_GESTURE_PAN_START_TIME;
if (conf->pan.moving_range <= 0) conf->pan.moving_range = E_GESTURE_PAN_MOVING_RANGE;
+}
+void
+_e_gesture_conf_pinch_check(E_Gesture_Conf_Edd *conf)
+{
if (conf->pinch.moving_distance_range <= 0.0) conf->pinch.moving_distance_range = E_GESTURE_PINCH_MOVING_DISTANCE_RANGE;
}
+
+
+void
+_e_gesture_conf_value_check(E_Gesture_Config_Data* gconfig)
+{
+ E_Gesture_Conf_Edd *conf;
+ if (!gconfig->conf) gconfig->conf = E_NEW(E_Gesture_Conf_Edd, 1);
+ EINA_SAFETY_ON_NULL_RETURN(gconfig->conf);
+
+ conf = gconfig->conf;
+
+ _e_gesture_conf_edge_swipe_check(conf);
+ _e_gesture_conf_edge_drag_check(conf);
+ _e_gesture_conf_tap_check(conf);
+ _e_gesture_conf_pan_check(conf);
+ _e_gesture_conf_pinch_check(conf);
+}
+
void
e_gesture_conf_init(E_Gesture_Config_Data *gconfig)
{