[libhandy] swipeable: Rename begin-swipe signal to swipe-began



commit e9add4b2c75f0059480f3374da7a762f513bbee1
Author: Alexander Mikhaylenko <alexm gnome org>
Date:   Sun Jun 14 23:11:51 2020 +0500

    swipeable: Rename begin-swipe signal to swipe-began
    
    Fixes https://gitlab.gnome.org/GNOME/libhandy/-/issues/199
    
    Signed-off-by: Alexander Mikhaylenko <alexm gnome org>

 src/hdy-swipe-group.c |  4 ++--
 src/hdy-swipeable.c   | 12 ++++++------
 2 files changed, 8 insertions(+), 8 deletions(-)
---
diff --git a/src/hdy-swipe-group.c b/src/hdy-swipe-group.c
index 4434fe8e..ea948e31 100644
--- a/src/hdy-swipe-group.c
+++ b/src/hdy-swipe-group.c
@@ -118,7 +118,7 @@ child_switched_cb (HdySwipeGroup *self,
 }
 
 static void
-begin_swipe_cb (HdySwipeGroup          *self,
+swipe_began_cb (HdySwipeGroup          *self,
                 HdyNavigationDirection  direction,
                 HdySwipeable           *swipeable)
 {
@@ -185,7 +185,7 @@ hdy_swipe_group_add_swipeable (HdySwipeGroup *self,
   g_return_if_fail (HDY_IS_SWIPEABLE (swipeable));
 
   g_signal_connect_swapped (swipeable, "child-switched", G_CALLBACK (child_switched_cb), self);
-  g_signal_connect_swapped (swipeable, "begin-swipe", G_CALLBACK (begin_swipe_cb), self);
+  g_signal_connect_swapped (swipeable, "swipe-began", G_CALLBACK (swipe_began_cb), self);
   g_signal_connect_swapped (swipeable, "update-swipe", G_CALLBACK (update_swipe_cb), self);
   g_signal_connect_swapped (swipeable, "end-swipe", G_CALLBACK (end_swipe_cb), self);
 
diff --git a/src/hdy-swipeable.c b/src/hdy-swipeable.c
index 8c5b2452..181e33b7 100644
--- a/src/hdy-swipeable.c
+++ b/src/hdy-swipeable.c
@@ -26,7 +26,7 @@ G_DEFINE_INTERFACE (HdySwipeable, hdy_swipeable, GTK_TYPE_WIDGET)
 
 enum {
   SIGNAL_CHILD_SWITCHED,
-  SIGNAL_BEGIN_SWIPE,
+  SIGNAL_SWIPE_BEGAN,
   SIGNAL_UPDATE_SWIPE,
   SIGNAL_END_SWIPE,
   SIGNAL_LAST_SIGNAL,
@@ -60,7 +60,7 @@ hdy_swipeable_default_init (HdySwipeableInterface *iface)
                   G_TYPE_UINT, G_TYPE_INT64);
 
   /**
-   * HdySwipeable::begin-swipe:
+   * HdySwipeable::swipe-began:
    * @self: The #HdySwipeable instance
    * @direction: The direction of the swipe, can be 1 or -1
    *
@@ -69,10 +69,10 @@ hdy_swipeable_default_init (HdySwipeableInterface *iface)
    * The @direction value can be used to restrict the swipe to a certain
    * direction.
    *
-   * Since: 0.0.12
+   * Since: 1.0
    */
-  signals[SIGNAL_BEGIN_SWIPE] =
-    g_signal_new ("begin-swipe",
+  signals[SIGNAL_SWIPE_BEGAN] =
+    g_signal_new ("swipe-began",
                   G_TYPE_FROM_INTERFACE (iface),
                   G_SIGNAL_RUN_FIRST,
                   0,
@@ -181,7 +181,7 @@ hdy_swipeable_begin_swipe (HdySwipeable           *self,
 
   (* iface->begin_swipe) (self, direction, direct);
 
-  g_signal_emit (self, signals[SIGNAL_BEGIN_SWIPE], 0, direction);
+  g_signal_emit (self, signals[SIGNAL_SWIPE_BEGAN], 0, direction);
 }
 
 /**


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]