diff options
author | Matthias Clasen <matthiasc@src.gnome.org> | 2009-01-27 00:25:21 +0000 |
---|---|---|
committer | Matthias Clasen <matthiasc@src.gnome.org> | 2009-01-27 00:25:21 +0000 |
commit | 95caf23ddd3b7183498340411ef51edf7d365ad8 (patch) | |
tree | 1b54576e64f5b97a8930e98784dcd9a36d14d3a5 /gtk/gtkaction.c | |
parent | b7d09a27507624e9d288e89b6683b93d5635a23b (diff) | |
download | gtk+-95caf23ddd3b7183498340411ef51edf7d365ad8.tar.gz |
Block the previous action when calling reset() to prevent accidental
* gtk/gtkactivatable.c (gtk_activatable_do_set_related_action):
Block the previous action when calling reset() to prevent
accidental activation of the previous action.
* gtk/gtkaction.c (gtk_action_activate): Don't compare booleans.
* gtk/gtktoggleaction.c (gtk_toggle_action_set_active): Remove
extraneous braces.
svn path=/trunk/; revision=22225
Diffstat (limited to 'gtk/gtkaction.c')
-rw-r--r-- | gtk/gtkaction.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/gtk/gtkaction.c b/gtk/gtkaction.c index 6d29ca4e34..9ce778eaef 100644 --- a/gtk/gtkaction.c +++ b/gtk/gtkaction.c @@ -750,8 +750,10 @@ gtk_action_activate (GtkAction *action) { g_return_if_fail (GTK_IS_ACTION (action)); - if (action->private_data->activate_blocked == FALSE && - gtk_action_is_sensitive (action)) + if (action->private_data->activate_blocked) + return; + + if (gtk_action_is_sensitive (action)) _gtk_action_emit_activate (action); } |