From beea00bc7a9fe66211b54fdf9e752119d94244bd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Exp=C3=B3sito?= Date: Mon, 8 Nov 2021 18:05:16 +0100 Subject: [PATCH] gestures: rename event handlers MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Follow the name convention used in evdev-wheel.c and rename the handle event functions from "tp_gesture_[STATE]_handle_event" to "tp_gesture_handle_event_on_state_[STATE]". Signed-off-by: José Expósito --- src/evdev-mt-touchpad-gestures.c | 64 ++++++++++++++++---------------- 1 file changed, 32 insertions(+), 32 deletions(-) diff --git a/src/evdev-mt-touchpad-gestures.c b/src/evdev-mt-touchpad-gestures.c index c933bb0f..dc2b6536 100644 --- a/src/evdev-mt-touchpad-gestures.c +++ b/src/evdev-mt-touchpad-gestures.c @@ -555,9 +555,9 @@ tp_gesture_set_hold_timer(struct tp_dispatch *tp, uint64_t time) } static void -tp_gesture_none_handle_event(struct tp_dispatch *tp, - enum gesture_event event, - uint64_t time) +tp_gesture_handle_event_on_state_none(struct tp_dispatch *tp, + enum gesture_event event, + uint64_t time) { switch(event) { case GESTURE_EVENT_RESET: @@ -584,9 +584,9 @@ tp_gesture_none_handle_event(struct tp_dispatch *tp, } static void -tp_gesture_unknown_handle_event(struct tp_dispatch *tp, - enum gesture_event event, - uint64_t time) +tp_gesture_handle_event_on_state_unknown(struct tp_dispatch *tp, + enum gesture_event event, + uint64_t time) { switch(event) { case GESTURE_EVENT_RESET: @@ -624,9 +624,9 @@ tp_gesture_unknown_handle_event(struct tp_dispatch *tp, } static void -tp_gesture_hold_handle_event(struct tp_dispatch *tp, - enum gesture_event event, - uint64_t time) +tp_gesture_handle_event_on_state_hold(struct tp_dispatch *tp, + enum gesture_event event, + uint64_t time) { switch(event) { case GESTURE_EVENT_RESET: @@ -662,9 +662,9 @@ tp_gesture_hold_handle_event(struct tp_dispatch *tp, } static void -tp_gesture_hold_and_motion_handle_event(struct tp_dispatch *tp, - enum gesture_event event, - uint64_t time) +tp_gesture_handle_event_on_state_hold_and_motion(struct tp_dispatch *tp, + enum gesture_event event, + uint64_t time) { switch(event) { case GESTURE_EVENT_RESET: @@ -687,9 +687,9 @@ tp_gesture_hold_and_motion_handle_event(struct tp_dispatch *tp, } static void -tp_gesture_pointer_motion_handle_event(struct tp_dispatch *tp, - enum gesture_event event, - uint64_t time) +tp_gesture_handle_event_on_state_pointer_motion(struct tp_dispatch *tp, + enum gesture_event event, + uint64_t time) { struct tp_touch *first; struct phys_coords first_moved; @@ -725,9 +725,9 @@ tp_gesture_pointer_motion_handle_event(struct tp_dispatch *tp, } static void -tp_gesture_scroll_handle_event(struct tp_dispatch *tp, - enum gesture_event event, - uint64_t time) +tp_gesture_handle_event_on_state_scroll(struct tp_dispatch *tp, + enum gesture_event event, + uint64_t time) { switch(event) { case GESTURE_EVENT_RESET: @@ -747,9 +747,9 @@ tp_gesture_scroll_handle_event(struct tp_dispatch *tp, } static void -tp_gesture_pinch_handle_event(struct tp_dispatch *tp, - enum gesture_event event, - uint64_t time) +tp_gesture_handle_event_on_state_pinch(struct tp_dispatch *tp, + enum gesture_event event, + uint64_t time) { switch(event) { case GESTURE_EVENT_RESET: @@ -769,9 +769,9 @@ tp_gesture_pinch_handle_event(struct tp_dispatch *tp, } static void -tp_gesture_swipe_handle_event(struct tp_dispatch *tp, - enum gesture_event event, - uint64_t time) +tp_gesture_handle_event_on_state_swipe(struct tp_dispatch *tp, + enum gesture_event event, + uint64_t time) { switch(event) { case GESTURE_EVENT_RESET: @@ -801,28 +801,28 @@ tp_gesture_handle_event(struct tp_dispatch *tp, switch(tp->gesture.state) { case GESTURE_STATE_NONE: - tp_gesture_none_handle_event(tp, event, time); + tp_gesture_handle_event_on_state_none(tp, event, time); break; case GESTURE_STATE_UNKNOWN: - tp_gesture_unknown_handle_event(tp, event, time); + tp_gesture_handle_event_on_state_unknown(tp, event, time); break; case GESTURE_STATE_HOLD: - tp_gesture_hold_handle_event(tp, event, time); + tp_gesture_handle_event_on_state_hold(tp, event, time); break; case GESTURE_STATE_HOLD_AND_MOTION: - tp_gesture_hold_and_motion_handle_event(tp, event, time); + tp_gesture_handle_event_on_state_hold_and_motion(tp, event, time); break; case GESTURE_STATE_POINTER_MOTION: - tp_gesture_pointer_motion_handle_event(tp, event, time); + tp_gesture_handle_event_on_state_pointer_motion(tp, event, time); break; case GESTURE_STATE_SCROLL: - tp_gesture_scroll_handle_event(tp, event, time); + tp_gesture_handle_event_on_state_scroll(tp, event, time); break; case GESTURE_STATE_PINCH: - tp_gesture_pinch_handle_event(tp, event, time); + tp_gesture_handle_event_on_state_pinch(tp, event, time); break; case GESTURE_STATE_SWIPE: - tp_gesture_swipe_handle_event(tp, event, time); + tp_gesture_handle_event_on_state_swipe(tp, event, time); break; }