[gtk/actionable-fixes: 6/6] checkbutton: Fix actionable state tracking
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/actionable-fixes: 6/6] checkbutton: Fix actionable state tracking
- Date: Thu, 10 Jun 2021 12:38:44 +0000 (UTC)
commit 3418504b4b103850b6a83d33319aaecc3c5d0d83
Author: Matthias Clasen <mclasen redhat com>
Date: Thu Jun 10 08:37:13 2021 -0400
checkbutton: Fix actionable state tracking
If we have a GAction as model, we just have to
call gtk_action_helper_activate() and let
the action helper handle the state updates,
Fixes: #4022
gtk/gtkcheckbutton.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/gtk/gtkcheckbutton.c b/gtk/gtkcheckbutton.c
index 0ed5bf8dd3..b5c2eecab2 100644
--- a/gtk/gtkcheckbutton.c
+++ b/gtk/gtkcheckbutton.c
@@ -325,10 +325,10 @@ click_released_cb (GtkGestureClick *gesture,
gtk_gesture_set_state (GTK_GESTURE (gesture), GTK_EVENT_SEQUENCE_CLAIMED);
- gtk_check_button_set_active (self, !priv->active);
-
if (priv->action_helper)
gtk_action_helper_activate (priv->action_helper);
+ else
+ gtk_check_button_set_active (self, !priv->active);
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]