2005-03-19 [holger] 1.9.6cvs1
authorHolger Berndt <hb@claws-mail.org>
Sat, 19 Mar 2005 03:19:22 +0000 (03:19 +0000)
committerHolger Berndt <hb@claws-mail.org>
Sat, 19 Mar 2005 03:19:22 +0000 (03:19 +0000)
* src/summaryview.c
* src/summaryview.h
Sync with HEAD

ChangeLog-gtk2.claws
PATCHSETS
configure.ac
src/summaryview.c
src/summaryview.h

index 87fae5cf2612423ec9c2ae0242bb3fa9b55de90f..2836ad92e9b1bc36f08dc11cfdf6c9e8fa430d5d 100644 (file)
@@ -1,3 +1,9 @@
+2005-03-19 [holger]    1.9.6cvs1
+
+       * src/summaryview.c
+       * src/summaryview.h
+               Sync with HEAD
+
 2005-03-18 [paul]      1.9.6
 
        initial GTK2 release
index 896830a033c6d915107bd902afcf2624f93984b7..733306c0fdfe2308e86b1b33a0d3ae92da61e559 100644 (file)
--- a/PATCHSETS
+++ b/PATCHSETS
 ( cvs diff -u -r 1.26.2.12 -r 1.26.2.13 src/foldersel.c; ) > 1.0.3cvs2.5.patchset
 ( cvs diff -u -r 1.395.2.59 -r 1.395.2.60 src/summaryview.c; ) > 1.0.3cvs2.6.patchset
 ( cvs diff -u -r 1.100.2.13 -r 1.100.2.14 AUTHORS; cvs diff -u -r 1.2504.2.53 -r 1.2504.2.54 ChangeLog.claws; cvs diff -u -r 1.654.2.451 -r 1.654.2.452 configure.ac; cvs diff -u -r 1.4.2.7 -r 1.4.2.8 src/gtk/about.c; cvs diff -u -r 1.1 -r 1.2 src/pixmaps/sylpheed_logo.xpm; ) > 1.0.3cvs3.1.patchset
+( cvs diff -u -r 1.395.2.60 -r 1.395.2.61 src/summaryview.c; cvs diff -u -r 1.68.2.5 -r 1.68.2.6 src/summaryview.h; ) > 1.9.6cvs1.patchset
index 67859a547a41a566e167ee7f3dbbaf6096fa1444..dbba4eb022719984cd0737e6491ac0e9d214069d 100644 (file)
@@ -11,7 +11,7 @@ MINOR_VERSION=9
 MICRO_VERSION=6
 INTERFACE_AGE=0
 BINARY_AGE=0
-EXTRA_VERSION=0
+EXTRA_VERSION=1
 EXTRA_RELEASE=
 EXTRA_GTK2_VERSION=
 
index 06ed224be4b7e535460396cdb6f03786f7506421..3bc45cafcbdd5f5c7acaa724e89284e82f34bbf2 100644 (file)
@@ -3891,11 +3891,6 @@ void summary_collapse_threads(SummaryView *summaryview)
 
 void summary_filter(SummaryView *summaryview, gboolean selected_only)
 {
-       if (!filtering_rules) {
-               alertpanel_error(_("No filter rules defined."));
-               return;
-       }
-
        summary_lock(summaryview);
 
        folder_item_update_freeze();
@@ -3906,37 +3901,21 @@ void summary_filter(SummaryView *summaryview, gboolean selected_only)
 
        gtk_clist_freeze(GTK_CLIST(summaryview->ctree));
 
-       if (filtering_rules == NULL) {
+       if (selected_only) {
+               GList *cur;
+
+               for (cur = GTK_CLIST(summaryview->ctree)->selection;
+                    cur != NULL; cur = cur->next) {
+                       summary_filter_func(GTK_CTREE(summaryview->ctree),
+                                           GTK_CTREE_NODE(cur->data),
+                                           summaryview);
+               }
+       } else {
                gtk_ctree_pre_recursive(GTK_CTREE(summaryview->ctree), NULL,
                                        GTK_CTREE_FUNC(summary_filter_func),
                                        summaryview);
-               
-               gtk_clist_thaw(GTK_CLIST(summaryview->ctree));
-               
-               if (prefs_common.immediate_exec) {
-                       summary_unlock(summaryview);
-                       summary_execute(summaryview);
-                       summary_lock(summaryview);
-               } else
-                       summary_status_show(summaryview);
-       }
-       else {
-               if (selected_only) {
-                       GList *cur;
-
-                       for (cur = GTK_CLIST(summaryview->ctree)->selection;
-                            cur != NULL; cur = cur->next) {
-                               summary_filter_func(GTK_CTREE(summaryview->ctree),
-                                                   GTK_CTREE_NODE(cur->data),
-                                                   summaryview);
-                       }
-               } else {
-                       gtk_ctree_pre_recursive(GTK_CTREE(summaryview->ctree), NULL,
-                                               GTK_CTREE_FUNC(summary_filter_func),
-                                               summaryview);
-               }
-               gtk_clist_thaw(GTK_CLIST(summaryview->ctree));
        }
+       gtk_clist_thaw(GTK_CLIST(summaryview->ctree));
 
        folder_item_update_thaw();
        debug_print("done.\n");
@@ -3949,16 +3928,19 @@ void summary_filter(SummaryView *summaryview, gboolean selected_only)
         * CLAWS: summary_show() only valid after having a lock. ideally
         * we want the lock to be context aware...  
         */
-       if (filtering_rules) {
-               summary_show(summaryview, summaryview->folder_item);
-       }               
+       summary_show(summaryview, summaryview->folder_item);
 }
 
 static void summary_filter_func(GtkCTree *ctree, GtkCTreeNode *node,
                                gpointer data)
 {
+       MailFilteringData mail_filtering_data;
        MsgInfo *msginfo = GTKUT_CTREE_NODE_GET_ROW_DATA(node);
 
+       mail_filtering_data.msginfo = msginfo;
+       if (hooks_invoke(MAIL_MANUAL_FILTERING_HOOKLIST, &mail_filtering_data))
+               return;
+
        filter_message_by_msginfo(filtering_rules, msginfo);
 }
 
index 93781a8fb1332d57882fba35686b12caed272b47..a8fc6a7da109322b948826018ddaa8152f722d9c 100644 (file)
@@ -33,6 +33,8 @@
 typedef struct _SummaryView            SummaryView;
 typedef struct _SummaryColumnState     SummaryColumnState;
 
+#define MAIL_MANUAL_FILTERING_HOOKLIST "mail_manual_filtering_hooklist"
+
 typedef enum
 {
        S_COL_MARK,