[libadwaita/wip/exalm/demo-cleanups: 21/21] demo-window: Consistently use swapped="yes" for signal handlers
- From: Christopher Davis <christopherdavis src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libadwaita/wip/exalm/demo-cleanups: 21/21] demo-window: Consistently use swapped="yes" for signal handlers
- Date: Thu, 9 Dec 2021 21:44:34 +0000 (UTC)
commit a0fadd968bc2b61c769014f317d0682dd1a5b5a1
Author: Alexander Mikhaylenko <alexm gnome org>
Date: Thu Dec 9 19:20:17 2021 +0500
demo-window: Consistently use swapped="yes" for signal handlers
demo/adw-demo-window.c | 10 +++-------
demo/adw-demo-window.ui | 8 ++++----
2 files changed, 7 insertions(+), 11 deletions(-)
---
diff --git a/demo/adw-demo-window.c b/demo/adw-demo-window.c
index 7b48a2ac..befb473e 100644
--- a/demo/adw-demo-window.c
+++ b/demo/adw-demo-window.c
@@ -59,23 +59,19 @@ notify_system_supports_color_schemes_cb (AdwDemoWindow *self)
}
static void
-notify_visible_child_cb (GObject *sender,
- GParamSpec *pspec,
- AdwDemoWindow *self)
+notify_visible_child_cb (AdwDemoWindow *self)
{
adw_leaflet_navigate (self->main_leaflet, ADW_NAVIGATION_DIRECTION_FORWARD);
}
static void
-back_clicked_cb (GtkWidget *sender,
- AdwDemoWindow *self)
+back_clicked_cb (AdwDemoWindow *self)
{
adw_leaflet_navigate (self->main_leaflet, ADW_NAVIGATION_DIRECTION_BACK);
}
static void
-leaflet_back_clicked_cb (GtkWidget *sender,
- AdwDemoWindow *self)
+leaflet_back_clicked_cb (AdwDemoWindow *self)
{
adw_leaflet_navigate (self->subpage_leaflet, ADW_NAVIGATION_DIRECTION_BACK);
}
diff --git a/demo/adw-demo-window.ui b/demo/adw-demo-window.ui
index 39f50f2c..f2b4339c 100644
--- a/demo/adw-demo-window.ui
+++ b/demo/adw-demo-window.ui
@@ -98,7 +98,7 @@
<property name="tooltip-text" translatable="yes">Back</property>
<property name="icon-name">go-previous-symbolic</property>
<property name="visible" bind-source="main_leaflet" bind-property="folded"
bind-flags="sync-create"/>
- <signal name="clicked" handler="back_clicked_cb"/>
+ <signal name="clicked" handler="back_clicked_cb" swapped="yes"/>
</object>
</child>
</object>
@@ -107,7 +107,7 @@
<object class="GtkStack" id="stack">
<property name="vexpand">True</property>
<property name="vhomogeneous">False</property>
- <signal name="notify::visible-child" handler="notify_visible_child_cb" after="yes"
swapped="no"/>
+ <signal name="notify::visible-child" handler="notify_visible_child_cb" after="yes"
swapped="yes"/>
<child>
<object class="GtkStackPage">
<property name="title" translatable="yes">Welcome</property>
@@ -203,7 +203,7 @@
<property name="title" translatable="yes">Toasts</property>
<property name="child">
<object class="AdwDemoPageToasts" id="toasts_page">
- <signal name="add-toast" handler="adw_toast_overlay_add_toast"
object="toast_overlay" swapped="true"/>
+ <signal name="add-toast" handler="adw_toast_overlay_add_toast"
object="toast_overlay" swapped="yes"/>
</object>
</property>
</object>
@@ -235,7 +235,7 @@
<property name="valign">center</property>
<property name="tooltip-text" translatable="yes">Back</property>
<property name="icon-name">go-previous-symbolic</property>
- <signal name="clicked" handler="leaflet_back_clicked_cb"/>
+ <signal name="clicked" handler="leaflet_back_clicked_cb" swapped="yes"/>
</object>
</child>
</object>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]