aboutsummaryrefslogtreecommitdiffstats
path: root/filter/rule-editor.c
diff options
context:
space:
mode:
authorJeffrey Stedfast <fejj@ximian.com>2003-04-30 01:08:40 +0800
committerJeffrey Stedfast <fejj@src.gnome.org>2003-04-30 01:08:40 +0800
commit8a3def40ba938b502f67a697704f67f31623465e (patch)
tree113c0ef6e80dafee9027ec3068de964c86df5bc1 /filter/rule-editor.c
parent71c542d2b38013e861e7fa16cf9a8e33865ea572 (diff)
downloadgsoc2013-evolution-8a3def40ba938b502f67a697704f67f31623465e.tar
gsoc2013-evolution-8a3def40ba938b502f67a697704f67f31623465e.tar.gz
gsoc2013-evolution-8a3def40ba938b502f67a697704f67f31623465e.tar.bz2
gsoc2013-evolution-8a3def40ba938b502f67a697704f67f31623465e.tar.lz
gsoc2013-evolution-8a3def40ba938b502f67a697704f67f31623465e.tar.xz
gsoc2013-evolution-8a3def40ba938b502f67a697704f67f31623465e.tar.zst
gsoc2013-evolution-8a3def40ba938b502f67a697704f67f31623465e.zip
Fix for bug #41578.
2003-04-24 Jeffrey Stedfast <fejj@ximian.com> Fix for bug #41578. * rule-editor.c (rule_move): Pass re->source instead of re->current->source to rule_context_get_rank_rule(). Also updated to pass re->source to rule_context_rank_rule(). (rule_editor_play_undo): Updated to pass re->source to rule_context_rank_rule(). * rule-context.c (rule_context_rank_rule): Now takes a 'source' argument rather than using rule->source (vfolder editor lists rules of all sources, not just same-source rules). (revert): Pass frule->source/part->source to rule_context_rank_rule() - might not be right but should preserve the prior behaviour at least. svn path=/trunk/; revision=21006
Diffstat (limited to 'filter/rule-editor.c')
-rw-r--r--filter/rule-editor.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/filter/rule-editor.c b/filter/rule-editor.c
index 05c1fd3589..32f368a06b 100644
--- a/filter/rule-editor.c
+++ b/filter/rule-editor.c
@@ -37,7 +37,7 @@ static int enable_undo = 0;
void rule_editor_add_undo (RuleEditor *re, int type, FilterRule *rule, int rank, int newrank);
void rule_editor_play_undo (RuleEditor *re);
-#define d(x)
+#define d(x)
static void set_source (RuleEditor *re, const char *source);
static void set_sensitive (RuleEditor *re);
@@ -445,10 +445,10 @@ rule_move (RuleEditor *re, int from, int to)
g_object_ref (re->current);
rule_editor_add_undo (re, RULE_EDITOR_LOG_RANK, re->current,
- rule_context_get_rank_rule (re->context, re->current, re->current->source), to);
+ rule_context_get_rank_rule (re->context, re->current, re->source), to);
d(printf ("moving %d to %d\n", from, to));
- rule_context_rank_rule (re->context, re->current, to);
+ rule_context_rank_rule (re->context, re->current, re->source, to);
path = gtk_tree_path_new ();
gtk_tree_path_append_index (path, from);
@@ -630,12 +630,12 @@ rule_editor_play_undo (RuleEditor *re)
d(printf ("Undoing remove on rule '%s'\n", undo->rule->name));
g_object_ref (undo->rule);
rule_context_add_rule (re->context, undo->rule);
- rule_context_rank_rule (re->context, undo->rule, undo->rank);
+ rule_context_rank_rule (re->context, undo->rule, re->source, undo->rank);
break;
case RULE_EDITOR_LOG_RANK:
rule = rule_context_find_rank_rule (re->context, undo->newrank, undo->rule->source);
if (rule)
- rule_context_rank_rule (re->context, rule, undo->rank);
+ rule_context_rank_rule (re->context, rule, re->source, undo->rank);
break;
}