aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeffrey Stedfast <fejj@ximian.com>2004-02-21 04:34:24 +0800
committerJeffrey Stedfast <fejj@src.gnome.org>2004-02-21 04:34:24 +0800
commit7418c7f7e1af79441e2f46351f791f338fafec7b (patch)
tree3d1a9edafc4535b3a40bf01d210b5a5a1e7c17db
parent36211f08ae7e3935d8665f6966dda660dd0fe224 (diff)
downloadgsoc2013-evolution-7418c7f7e1af79441e2f46351f791f338fafec7b.tar
gsoc2013-evolution-7418c7f7e1af79441e2f46351f791f338fafec7b.tar.gz
gsoc2013-evolution-7418c7f7e1af79441e2f46351f791f338fafec7b.tar.bz2
gsoc2013-evolution-7418c7f7e1af79441e2f46351f791f338fafec7b.tar.lz
gsoc2013-evolution-7418c7f7e1af79441e2f46351f791f338fafec7b.tar.xz
gsoc2013-evolution-7418c7f7e1af79441e2f46351f791f338fafec7b.tar.zst
gsoc2013-evolution-7418c7f7e1af79441e2f46351f791f338fafec7b.zip
After setting the new selected iter, call cursor_changed() so we can
2004-02-20 Jeffrey Stedfast <fejj@ximian.com> * rule-editor.c (rule_delete): After setting the new selected iter, call cursor_changed() so we can update state. Fixes bug #54205. svn path=/trunk/; revision=24823
-rw-r--r--filter/ChangeLog6
-rw-r--r--filter/rule-editor.c7
2 files changed, 13 insertions, 0 deletions
diff --git a/filter/ChangeLog b/filter/ChangeLog
index 372d32b4ec..592045ef37 100644
--- a/filter/ChangeLog
+++ b/filter/ChangeLog
@@ -1,3 +1,9 @@
+2004-02-20 Jeffrey Stedfast <fejj@ximian.com>
+
+ * rule-editor.c (rule_delete): After setting the new selected
+ iter, call cursor_changed() so we can update state. Fixes bug
+ #54205.
+
2004-02-20 Not Zed <NotZed@Ximian.com>
** See bug #54338.
diff --git a/filter/rule-editor.c b/filter/rule-editor.c
index 861605878d..320e9851e1 100644
--- a/filter/rule-editor.c
+++ b/filter/rule-editor.c
@@ -43,6 +43,8 @@ static void set_source (RuleEditor *re, const char *source);
static void set_sensitive (RuleEditor *re);
static FilterRule *create_rule (RuleEditor *re);
+static void cursor_changed (GtkTreeView *treeview, RuleEditor *re);
+
static void rule_editor_class_init (RuleEditorClass *klass);
static void rule_editor_init (RuleEditor *re);
static void rule_editor_finalise (GObject *obj);
@@ -422,6 +424,7 @@ rule_delete (GtkWidget *widget, RuleEditor *re)
gtk_tree_model_get_iter (GTK_TREE_MODEL (re->model), &iter, path);
gtk_tree_path_free (path);
+ /* select the new row */
selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (re->list));
gtk_tree_selection_select_iter (selection, &iter);
@@ -429,6 +432,10 @@ rule_delete (GtkWidget *widget, RuleEditor *re)
path = gtk_tree_model_get_path ((GtkTreeModel *) re->model, &iter);
gtk_tree_view_scroll_to_cell (re->list, path, NULL, FALSE, 0.0, 0.0);
gtk_tree_path_free (path);
+
+ /* update our selection state */
+ cursor_changed (re->list, re);
+ return;
}
}