fix a bug about filtering and bounce, be careful, filtering or bouncing action can...
authorHoà Viêt Dinh <dinh.viet.hoa@free.fr>
Wed, 16 Jan 2002 22:25:21 +0000 (22:25 +0000)
committerHoà Viêt Dinh <dinh.viet.hoa@free.fr>
Wed, 16 Jan 2002 22:25:21 +0000 (22:25 +0000)
ChangeLog.claws
src/matcher_parser_parse.y
src/prefs_filtering.c

index a6ee6389a26b273e2e9efda775fdceb7737d6181..3fb0afee1fca4440c23438396b477fdf4168e45f 100644 (file)
@@ -1,3 +1,11 @@
+2001-12-08 [hoa]       0.7.0claws10
+
+       * src/matcher_parser_parse.y
+               fixed some bugs
+
+       * src/prefs_filtering.c
+               now, we can use bounce action in the dialog box.
+
 2002-01-16 [carsten]   0.7.0claws9
        * src/gtkstext.c
                removed the <control> and <alt> shortcuts because they're
 2002-01-16 [carsten]   0.7.0claws9
        * src/gtkstext.c
                removed the <control> and <alt> shortcuts because they're
index 55ac707c84d04690d1d434b35e669df3a471316f..685bbd97bc81fc0a9d624f73dcae1b655e702875 100644 (file)
@@ -769,7 +769,7 @@ MATCHER_EXECUTE MATCHER_STRING
        gint account_id = 0;
 
        action_type = MATCHACTION_FORWARD;
        gint account_id = 0;
 
        action_type = MATCHACTION_FORWARD;
-       account_id = $2;
+       account_id = atoi($2);
        destination = $3;
        action = filteringaction_new(action_type, account_id, destination, 0);
 }
        destination = $3;
        action = filteringaction_new(action_type, account_id, destination, 0);
 }
@@ -780,7 +780,7 @@ MATCHER_EXECUTE MATCHER_STRING
        gint account_id = 0;
 
        action_type = MATCHACTION_FORWARD_AS_ATTACHMENT;
        gint account_id = 0;
 
        action_type = MATCHACTION_FORWARD_AS_ATTACHMENT;
-       account_id = $2;
+       account_id = atoi($2);
        destination = $3;
        action = filteringaction_new(action_type, account_id, destination, 0);
 }
        destination = $3;
        action = filteringaction_new(action_type, account_id, destination, 0);
 }
@@ -791,7 +791,7 @@ MATCHER_EXECUTE MATCHER_STRING
        gint account_id = 0;
 
        action_type = MATCHACTION_BOUNCE;
        gint account_id = 0;
 
        action_type = MATCHACTION_BOUNCE;
-       account_id = $2;
+       account_id = atoi($2);
        destination = $3;
        action = filteringaction_new(action_type, account_id, destination, 0);
 }
        destination = $3;
        action = filteringaction_new(action_type, account_id, destination, 0);
 }
index 055b4572e983f02815f3ea0441840fd5747319ee..f50407cc03d127fad8b613a00343a2e2c3dce633 100644 (file)
@@ -203,6 +203,8 @@ static gint prefs_filtering_get_matching_from_action(gint action_id)
                return MATCHACTION_FORWARD;
        case ACTION_FORWARD_AS_ATTACHMENT:
                return MATCHACTION_FORWARD_AS_ATTACHMENT;
                return MATCHACTION_FORWARD;
        case ACTION_FORWARD_AS_ATTACHMENT:
                return MATCHACTION_FORWARD_AS_ATTACHMENT;
+       case ACTION_BOUNCE:
+               return MATCHACTION_BOUNCE;
        case ACTION_EXECUTE:
                return MATCHACTION_EXECUTE;
        case ACTION_COLOR:
        case ACTION_EXECUTE:
                return MATCHACTION_EXECUTE;
        case ACTION_COLOR:
@@ -939,9 +941,9 @@ static void prefs_filtering_select_set(FilteringProp * prop)
                                     ACTION_MARK_AS_UNREAD);
                break;
        case MATCHACTION_FORWARD:
                                     ACTION_MARK_AS_UNREAD);
                break;
        case MATCHACTION_FORWARD:
+               list_id = get_list_id_from_account_id(action->account_id);
                gtk_list_select_item(GTK_LIST(filtering.action_list),
                                     ACTION_FORWARD);
                gtk_list_select_item(GTK_LIST(filtering.action_list),
                                     ACTION_FORWARD);
-               list_id = get_list_id_from_account_id(action->account_id);
                gtk_list_select_item(GTK_LIST(filtering.account_list),
                                     list_id);
                break;
                gtk_list_select_item(GTK_LIST(filtering.account_list),
                                     list_id);
                break;
@@ -953,9 +955,9 @@ static void prefs_filtering_select_set(FilteringProp * prop)
                                     list_id);
                break;
        case MATCHACTION_BOUNCE:
                                     list_id);
                break;
        case MATCHACTION_BOUNCE:
+               list_id = get_list_id_from_account_id(action->account_id);
                gtk_list_select_item(GTK_LIST(filtering.action_list),
                                     ACTION_BOUNCE);
                gtk_list_select_item(GTK_LIST(filtering.action_list),
                                     ACTION_BOUNCE);
-               list_id = get_list_id_from_account_id(action->account_id);
                gtk_list_select_item(GTK_LIST(filtering.account_list),
                                     list_id);
                break;
                gtk_list_select_item(GTK_LIST(filtering.account_list),
                                     list_id);
                break;