diff options
author | Rui Matos <tiagomatos@gmail.com> | 2011-12-14 02:29:38 +0000 |
---|---|---|
committer | Rui Matos <tiagomatos@gmail.com> | 2011-12-14 17:03:44 +0000 |
commit | 1235dc320b930965fabfa9d5c1429e92dc282424 (patch) | |
tree | d18c777c05621f68b29c568c14789cb8233ec401 /gtk/gtkwidget.c | |
parent | 40423df23428109c75119d7291f876785f0db73f (diff) | |
download | gtk+-1235dc320b930965fabfa9d5c1429e92dc282424.tar.gz |
widget: Synthesize crossing only if sensitivity changed while propagating state
Diffstat (limited to 'gtk/gtkwidget.c')
-rw-r--r-- | gtk/gtkwidget.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/gtk/gtkwidget.c b/gtk/gtkwidget.c index 6b96be4141..47887470e0 100644 --- a/gtk/gtkwidget.c +++ b/gtk/gtkwidget.c @@ -10704,7 +10704,8 @@ gtk_widget_propagate_state (GtkWidget *widget, g_signal_emit (widget, widget_signals[STATE_CHANGED], 0, old_state); g_signal_emit (widget, widget_signals[STATE_FLAGS_CHANGED], 0, old_flags); - if (!priv->shadowed) + if (!priv->shadowed && + (new_flags & GTK_STATE_FLAG_INSENSITIVE) != (old_flags & GTK_STATE_FLAG_INSENSITIVE)) { GList *event_windows = NULL; GList *devices, *d; @@ -10729,7 +10730,7 @@ gtk_widget_propagate_state (GtkWidget *widget, if (!gtk_widget_is_sensitive (widget)) _gtk_widget_synthesize_crossing (widget, NULL, d->data, GDK_CROSSING_STATE_CHANGED); - else if (old_flags & GTK_STATE_FLAG_INSENSITIVE) + else _gtk_widget_synthesize_crossing (NULL, widget, d->data, GDK_CROSSING_STATE_CHANGED); |