summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2011-08-23 23:29:19 -0400
committerMatthias Clasen <mclasen@redhat.com>2011-08-23 23:29:19 -0400
commitc83db6cdf06d4b013b486abb4ca23538eec3555a (patch)
tree8630dba67b33e32405aac03abb00a24c45e4508f
parentc9023cadbfed9a4831287a366cc3367c7baa436c (diff)
downloadgtk+-c83db6cdf06d4b013b486abb4ca23538eec3555a.tar.gz
GtkSwitch: Return FALSE from the button press handler
This makes the behavior identical to other widgets which handle button presses, and it avoids problems when placing switches into a windows main toolbar. https://bugzilla.gnome.org/show_bug.cgi?id=656986
-rw-r--r--gtk/gtkswitch.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/gtk/gtkswitch.c b/gtk/gtkswitch.c
index 8604079cf0..acb306db53 100644
--- a/gtk/gtkswitch.c
+++ b/gtk/gtkswitch.c
@@ -112,7 +112,7 @@ gtk_switch_button_press (GtkWidget *widget,
if (event->x <= allocation.width / 2)
{
priv->in_press = TRUE;
- return FALSE;
+ return TRUE;
}
priv->offset = event->x - allocation.width / 2;
@@ -125,7 +125,7 @@ gtk_switch_button_press (GtkWidget *widget,
if (event->x >= allocation.width / 2)
{
priv->in_press = TRUE;
- return FALSE;
+ return TRUE;
}
priv->offset = event->x;
@@ -137,7 +137,7 @@ gtk_switch_button_press (GtkWidget *widget,
"gtk-dnd-drag-threshold", &priv->drag_threshold,
NULL);
- return FALSE;
+ return TRUE;
}
static gboolean