sync with sylpheed 0.4.67cvs7-8
authorAlfons Hoogervorst <alfons@proteus.demon.nl>
Thu, 17 May 2001 13:25:31 +0000 (13:25 +0000)
committerAlfons Hoogervorst <alfons@proteus.demon.nl>
Thu, 17 May 2001 13:25:31 +0000 (13:25 +0000)
ChangeLog
ChangeLog.claws
ChangeLog.jp
src/compose.c
src/folder.c
src/folder.h
src/folderview.c
src/inc.c
src/mbox.c
src/mh.c
src/mh.h

index b729c06..db3a8ee 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,26 @@
+2001-05-15
+
+       * src/compose.c: compose_write_headers(): excluded also From, To,
+         Sender because they could be used for SPAM.
+       * src/folderview.c: add '+' mark to the collapsed folder that have
+         some unread folders.
+         folderview_search_new_recursive(),
+         folderview_have_new_children(),
+         folderview_search_unread_recursive(),
+         folderview_have_unread_children(),
+         folderview_find_collapsed_parent(): new.
+         folderview_update_node(): display the number of queued messages.
+
+2001-05-14
+
+       * src/folder.[ch]
+         src/mh.[ch]: modified *_add_msg() to use link(). Added the
+         argument to switch whether to remove the source file or not.
+       * src/compose.c
+         src/inc.c
+         src/mbox.c: modified the argument of folder_item_add_msg() and
+         removed some unlink()'s.
+
 2001-05-13
 
        * src/prefs_customheader.[ch]: renamed prefs_headers_* to
@@ -12,6 +35,9 @@
          header list.
        * src/compose.c: compose_write_headers(): modified the order of
          headers, and made it encode the custom headers.
+       * src/prefs_customheader.c: prefs_custom_header_delete_cb()
+         src/prefs_filter.c: prefs_filter_delete_cb(): treat closing the
+         alert panel by ESC as "No".
 
 2001-05-13
 
index 47e3d3f..2318f3e 100644 (file)
@@ -1,3 +1,7 @@
+2001-05-17 [alfons]
+
+       * sync with sylpheed 0.4.67cvs7-8
+
 2001-05-17 [hoa]
 
 * src/Makefile.am
index e91da63..64acea9 100644 (file)
@@ -1,3 +1,27 @@
+2001-05-15
+
+       * src/compose.c: compose_write_headers(): SPAM ¤Ë»ÈÍѤµ¤ì¤ë²ÄǽÀ­
+         ¤¬¤¢¤ë¤Î¤Ç¡¢ From, To, Sender ¤â½ü³°¤¹¤ë¤è¤¦¤Ë¤·¤¿¡£
+       * src/folderview.c: Ì¤ÆÉ¥Õ¥©¥ë¥À¤¬¤¢¤ëÀÞ¤ê¾ö¤Þ¤ì¤¿¥Õ¥©¥ë¥À¤Ë '+'
+         ¥Þ¡¼¥¯¤òÉÕ¤±¤ë¤è¤¦¤Ë¤·¤¿¡£
+         folderview_search_new_recursive(),
+         folderview_have_new_children(),
+         folderview_search_unread_recursive(),
+         folderview_have_unread_children(),
+         folderview_find_collapsed_parent(): ¿·µ¬¡£
+         folderview_update_node(): ¥­¥å¡¼¤µ¤ì¤¿¥á¥Ã¥»¡¼¥¸¤Î¿ô¤òɽ¼¨¤¹¤ë
+         ¤è¤¦¤Ë¤·¤¿¡£
+
+2001-05-14
+
+       * src/folder.[ch]
+         src/mh.[ch]: *_add_msg() ¤ò link() ¤ò»ÈÍѤ¹¤ë¤è¤¦¤Ë½¤Àµ¡£
+         ¸µ¤Î¥Õ¥¡¥¤¥ë¤òºï½ü¤¹¤ë¤«¤É¤¦¤«¤òÀÚÂؤ¨¤ë°ú¿ô¤òÄɲá£
+       * src/compose.c
+         src/inc.c
+         src/mbox.c: folder_item_add_msg() ¤Î°ú¿ô¤ò½¤Àµ¤·¡¢¤¤¤¯¤Ä¤«¤Î
+         unlink() ¤òºï½ü¡£
+
 2001-05-13
 
        * src/prefs_customheader.[ch]: prefs_headers_* ¤ò
@@ -12,6 +36,9 @@
          ¤·¤¿¡£
        * src/compose.c: compose_write_headers(): ¥Ø¥Ã¥À¤Î½ç½ø¤ò½¤Àµ¤·¡¢
          ¥«¥¹¥¿¥à¥Ø¥Ã¥À¤ò¥¨¥ó¥³¡¼¥É¤¹¤ë¤è¤¦¤Ë¤·¤¿¡£
+       * src/prefs_customheader.c: prefs_custom_header_delete_cb()
+         src/prefs_filter.c: prefs_filter_delete_cb(): ESC ¤Ç·Ù¹ð¥Ñ¥Í¥ë
+         ¤òÊĤ¸¤ë¤Î¤ò¡Ö¤¤¤¤¤¨¡×¤È¤·¤Æ°·¤¦¤è¤¦¤Ë¤·¤¿¡£
 
 2001-05-13
 
index 73bacae..88c2535 100644 (file)
@@ -1485,7 +1485,7 @@ static gint compose_send(Compose *compose)
                                (_("Can't save the message to outbox."));
        }
 
-       if (unlink(tmp) < 0) FILE_OP_ERROR(tmp, "unlink");
+       unlink(tmp);
        lock = FALSE;
        return ok;
 }
@@ -1665,7 +1665,7 @@ static gint compose_save_to_outbox(Compose *compose, const gchar *file)
 
        outbox = folder_get_default_outbox();
        folder_item_scan(outbox);
-       if ((num = folder_item_add_msg(outbox, file)) < 0) {
+       if ((num = folder_item_add_msg(outbox, file, FALSE)) < 0) {
                g_warning(_("can't save message\n"));
                return -1;
        }
@@ -1769,13 +1769,12 @@ static gint compose_queue(Compose *compose, const gchar *file)
 
        queue = folder_get_default_queue();
        folder_item_scan(queue);
-       if ((num = folder_item_add_msg(queue, tmp)) < 0) {
+       if ((num = folder_item_add_msg(queue, tmp, TRUE)) < 0) {
                g_warning(_("can't queue the message\n"));
                unlink(tmp);
                g_free(tmp);
                return -1;
        }
-       unlink(tmp);
        g_free(tmp);
 
        queue_path = folder_item_get_path(queue);
@@ -2080,6 +2079,9 @@ static gint compose_write_headers(Compose *compose, FILE *fp,
                        CustomHeader *chdr = (CustomHeader *)cur->data;
 
                        if (strcasecmp(chdr->name, "Date")         != 0 &&
+                           strcasecmp(chdr->name, "From")         != 0 &&
+                           strcasecmp(chdr->name, "To")           != 0 &&
+                           strcasecmp(chdr->name, "Sender")       != 0 &&
                            strcasecmp(chdr->name, "Message-Id")   != 0 &&
                            strcasecmp(chdr->name, "In-Reply-To")  != 0 &&
                            strcasecmp(chdr->name, "References")   != 0 &&
@@ -3657,13 +3659,12 @@ static void compose_draft_cb(gpointer data, guint action, GtkWidget *widget)
                return;
        }
 
-       if (folder_item_add_msg(draft, tmp) < 0) {
+       if (folder_item_add_msg(draft, tmp, TRUE) < 0) {
                unlink(tmp);
                g_free(tmp);
                return;
        }
 
-       unlink(tmp);
        g_free(tmp);
 
        //folderview_scan_folder_a(DRAFT_DIR, TRUE);
index 0e5e588..6d06c20 100644 (file)
@@ -489,7 +489,8 @@ gchar *folder_item_fetch_msg(FolderItem *item, gint num)
        return folder->fetch_msg(folder, item, num);
 }
 
-gint folder_item_add_msg(FolderItem *dest, const gchar *file)
+gint folder_item_add_msg(FolderItem *dest, const gchar *file,
+                        gboolean remove_source)
 {
        Folder *folder;
        gint num;
@@ -501,7 +502,7 @@ gint folder_item_add_msg(FolderItem *dest, const gchar *file)
        folder = dest->folder;
        if (dest->last_num < 0) folder->scan(folder, dest);
 
-       num = folder->add_msg(folder, dest, file);
+       num = folder->add_msg(folder, dest, file, remove_source);
        if (num > 0) dest->last_num = num;
 
        return num;
index 2951b48..1a0cf80 100644 (file)
@@ -108,7 +108,8 @@ struct _Folder
                                         gint            num);
        gint     (*add_msg)             (Folder         *folder,
                                         FolderItem     *dest,
-                                        const gchar    *file);
+                                        const gchar    *file,
+                                        gboolean        remove_source);
        gint     (*move_msg)            (Folder         *folder,
                                         FolderItem     *dest,
                                         MsgInfo        *msginfo);
@@ -257,7 +258,8 @@ void   folder_item_scan_foreach             (GHashTable     *table);
 gchar *folder_item_fetch_msg           (FolderItem     *item,
                                         gint            num);
 gint   folder_item_add_msg             (FolderItem     *dest,
-                                        const gchar    *file);
+                                        const gchar    *file,
+                                        gboolean        remove_source);
 gint   folder_item_move_msg            (FolderItem     *dest,
                                         MsgInfo        *msginfo);
 gint   folder_item_move_msgs_with_dest (FolderItem     *dest,
index 199b01c..de27250 100644 (file)
@@ -1,6 +1,6 @@
 /*
  * Sylpheed -- a GTK+ based, lightweight, and fast e-mail client
- * Copyright (C) 1999,2000 Hiroyuki Yamamoto
+ * Copyright (C) 1999-2000 Hiroyuki Yamamoto
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -134,6 +134,12 @@ static void folderview_selected            (GtkCTree       *ctree,
                                         GtkCTreeNode   *row,
                                         gint            column,
                                         FolderView     *folderview);
+static void folderview_tree_expanded   (GtkCTree       *ctree,
+                                        GtkCTreeNode   *node,
+                                        FolderView     *folderview);
+static void folderview_tree_collapsed  (GtkCTree       *ctree,
+                                        GtkCTreeNode   *node,
+                                        FolderView     *folderview);
 static void folderview_popup_close     (GtkMenuShell   *menu_shell,
                                         FolderView     *folderview);
 static void folderview_col_resized     (GtkCList       *clist,
@@ -313,7 +319,16 @@ FolderView *folderview_create(void)
                           folderview);
        gtk_signal_connect(GTK_OBJECT(ctree), "tree_select_row",
                           GTK_SIGNAL_FUNC(folderview_selected), folderview);
-       gtk_signal_connect(GTK_OBJECT(ctree), "resize_column",
+
+
+       gtk_signal_connect_after(GTK_OBJECT(ctree), "tree_expand",
+                                GTK_SIGNAL_FUNC(folderview_tree_expanded),
+                                folderview);
+       gtk_signal_connect_after(GTK_OBJECT(ctree), "tree_collapse",
+                                GTK_SIGNAL_FUNC(folderview_tree_collapsed),
+                                folderview);
+
+    gtk_signal_connect(GTK_OBJECT(ctree), "resize_column",
                           GTK_SIGNAL_FUNC(folderview_col_resized),
                           folderview);
 
@@ -579,6 +594,111 @@ void folderview_update_all(void)
        gtk_widget_destroy(window);
 }
 
+static gboolean folderview_search_new_recursive(GtkCTree *ctree,
+                                               GtkCTreeNode *node)
+{
+       FolderItem *item;
+
+       if (node) {
+               item = gtk_ctree_node_get_row_data(ctree, node);
+               if (item) {
+                       if (item->new > 0 ||
+                           (item->stype == F_QUEUE && item->total > 0))
+                               return TRUE;
+               }
+               node = GTK_CTREE_ROW(node)->children;
+       } else
+               node = GTK_CTREE_NODE(GTK_CLIST(ctree)->row_list);
+
+       while (node) {
+               if (folderview_search_new_recursive(ctree, node) == TRUE)
+                       return TRUE;
+               node = GTK_CTREE_ROW(node)->sibling;
+       }
+
+       return FALSE;
+}
+
+static gboolean folderview_have_new_children(FolderView *folderview,
+                                            GtkCTreeNode *node)
+{
+       GtkCTree *ctree = GTK_CTREE(folderview->ctree);
+
+       if (!node)
+               node = GTK_CTREE_NODE(GTK_CLIST(ctree)->row_list);
+       if (!node)
+               return FALSE;
+
+       node = GTK_CTREE_ROW(node)->children;
+
+       while (node) {
+               if (folderview_search_new_recursive(ctree, node) == TRUE)
+                       return TRUE;
+               node = GTK_CTREE_ROW(node)->sibling;
+       }
+
+       return FALSE;
+}
+
+static gboolean folderview_search_unread_recursive(GtkCTree *ctree,
+                                                  GtkCTreeNode *node)
+{
+       FolderItem *item;
+
+       if (node) {
+               item = gtk_ctree_node_get_row_data(ctree, node);
+               if (item) {
+                       if (item->unread > 0 ||
+                           (item->stype == F_QUEUE && item->total > 0))
+                               return TRUE;
+               }
+               node = GTK_CTREE_ROW(node)->children;
+       } else
+               node = GTK_CTREE_NODE(GTK_CLIST(ctree)->row_list);
+
+       while (node) {
+               if (folderview_search_unread_recursive(ctree, node) == TRUE)
+                       return TRUE;
+               node = GTK_CTREE_ROW(node)->sibling;
+       }
+
+       return FALSE;
+}
+
+static gboolean folderview_have_unread_children(FolderView *folderview,
+                                               GtkCTreeNode *node)
+{
+       GtkCTree *ctree = GTK_CTREE(folderview->ctree);
+
+       if (!node)
+               node = GTK_CTREE_NODE(GTK_CLIST(ctree)->row_list);
+       if (!node)
+               return FALSE;
+
+       node = GTK_CTREE_ROW(node)->children;
+
+       while (node) {
+               if (folderview_search_unread_recursive(ctree, node) == TRUE)
+                       return TRUE;
+               node = GTK_CTREE_ROW(node)->sibling;
+       }
+
+       return FALSE;
+}
+
+static GtkCTreeNode *folderview_find_collapsed_parent(FolderView *folderview,
+                                                     GtkCTreeNode *node)
+{
+       if (!node) return NULL;
+
+       while ((node = GTK_CTREE_ROW(node)->parent) != NULL) {
+               if (!GTK_CTREE_ROW(node)->expanded)
+                       return node;
+       }
+
+       return NULL;
+}
+
 static void folderview_update_node(FolderView *folderview, GtkCTreeNode *node)
 {
        GtkCTree *ctree = GTK_CTREE(folderview->ctree);
@@ -587,6 +707,9 @@ static void folderview_update_node(FolderView *folderview, GtkCTreeNode *node)
        GdkPixmap *xpm, *openxpm;
        GdkBitmap *mask, *openmask;
        gchar *name;
+       gchar *str;
+       gboolean add_unread_mark;
+       gboolean use_bold, use_color;
 
        item = gtk_ctree_node_get_row_data(ctree, node);
        g_return_if_fail(item != NULL);
@@ -639,9 +762,29 @@ static void folderview_update_node(FolderView *folderview, GtkCTreeNode *node)
                } else
                        name = g_strdup(item->name);
        }
-       if (item->unread > 0 && prefs_common.display_folder_unread) {
-               gchar *str;
 
+       if (!GTK_CTREE_ROW(node)->expanded &&
+           folderview_have_unread_children(folderview, node))
+               add_unread_mark = TRUE;
+       else
+               add_unread_mark = FALSE;
+
+       if (item->stype == F_QUEUE && item->total > 0 &&
+           prefs_common.display_folder_unread) {
+               str = g_strdup_printf("%s (%d%s)", name, item->total,
+                                     add_unread_mark ? "+" : "");
+               gtk_ctree_set_node_info(ctree, node, str, FOLDER_SPACING,
+                                       xpm, mask, openxpm, openmask,
+                                       FALSE, GTK_CTREE_ROW(node)->expanded);
+               g_free(str);
+       } else if ((item->unread > 0 || add_unread_mark) &&
+                prefs_common.display_folder_unread) {
+
+               if (item->unread > 0)
+                       str = g_strdup_printf("%s (%d%s)", name, item->unread,
+                                             add_unread_mark ? "+" : "");
+               else
+                       str = g_strdup_printf("%s (+)", name);
                str = g_strdup_printf("%s (%d)", name, item->unread);
                gtk_ctree_set_node_info(ctree, node, str, FOLDER_SPACING,
                                        xpm, mask, openxpm, openmask,
@@ -657,7 +800,6 @@ static void folderview_update_node(FolderView *folderview, GtkCTreeNode *node)
                gtk_ctree_node_set_text(ctree, node, COL_NEW,    "-");
                gtk_ctree_node_set_text(ctree, node, COL_UNREAD, "-");
                gtk_ctree_node_set_text(ctree, node, COL_TOTAL,  "-");
-               return;
        } else {
                gtk_ctree_node_set_text(ctree, node, COL_NEW,    itos(item->new));
                gtk_ctree_node_set_text(ctree, node, COL_UNREAD, itos(item->unread));
@@ -671,36 +813,44 @@ static void folderview_update_node(FolderView *folderview, GtkCTreeNode *node)
        if (!prev_style)
                prev_style = ctree_style;
        style = gtk_style_copy(prev_style);
+       if (!style) return;
 
-       if (style) {
-               gboolean use_bold, use_color;
-
-               if (item->stype == F_QUEUE) {
-                       /* highlight queue folder if there are any messages */
-                       use_bold = use_color = (item->total > 0);
-               } else {
-                       /* if unread messages exist, print with bold font */
-                       use_bold = (item->unread > 0);
-                       /* if new messages exist, print with colored letter */
-                       use_color = (item->new > 0);
-               }
+       if (item->stype == F_QUEUE) {
+               /* highlight queue folder if there are any messages */
+               use_bold = use_color = (item->total > 0);
+       } else {
+               /* if unread messages exist, print with bold font */
+               use_bold = (item->unread > 0) || add_unread_mark;
+               /* if new messages exist, print with colored letter */
+               use_color =
+                       (item->new > 0) ||
+                       (add_unread_mark &&
+                        folderview_have_new_children(folderview, node));
+       }
 
-               if (use_bold && boldfont)
-                       style->font = boldfont;
-               else
-                       style->font = ctree_style->font;
-
-               if (use_color) {
-                       style->fg[GTK_STATE_NORMAL]   = folderview->color_new;
-                       style->fg[GTK_STATE_SELECTED] = folderview->color_new;
-               } else {
-                       style->fg[GTK_STATE_NORMAL] =
-                               ctree_style->fg[GTK_STATE_NORMAL];
-                       style->fg[GTK_STATE_SELECTED] =
-                               ctree_style->fg[GTK_STATE_SELECTED];
-               }
+       if (use_bold && boldfont)
+               style->font = boldfont;
+       else
+               style->font = ctree_style->font;
 
-               gtk_ctree_node_set_row_style(ctree, node, style);
+       if (use_color) {
+               style->fg[GTK_STATE_NORMAL]   = folderview->color_new;
+               style->fg[GTK_STATE_SELECTED] = folderview->color_new;
+       } else {
+               style->fg[GTK_STATE_NORMAL] =
+                       ctree_style->fg[GTK_STATE_NORMAL];
+               style->fg[GTK_STATE_SELECTED] =
+                       ctree_style->fg[GTK_STATE_SELECTED];
+       }
+
+       gtk_ctree_node_set_row_style(ctree, node, style);
+
+       if (use_bold) {
+               GtkCTreeNode *parent;
+
+               parent = folderview_find_collapsed_parent(folderview, node);
+               if (parent)
+                       folderview_update_node(folderview, parent);
        }
 }
 
@@ -1080,6 +1230,18 @@ static void folderview_selected(GtkCTree *ctree, GtkCTreeNode *row,
        can_select = TRUE;
 }
 
+static void folderview_tree_expanded(GtkCTree *ctree, GtkCTreeNode *node,
+                                    FolderView *folderview)
+{
+       folderview_update_node(folderview, node);
+}
+
+static void folderview_tree_collapsed(GtkCTree *ctree, GtkCTreeNode *node,
+                                     FolderView *folderview)
+{
+       folderview_update_node(folderview, node);
+}
+
 static void folderview_popup_close(GtkMenuShell *menu_shell,
                                   FolderView *folderview)
 {
index 6588b60..811e9fe 100644 (file)
--- a/src/inc.c
+++ b/src/inc.c
@@ -812,13 +812,11 @@ gint inc_drop_message(const gchar *file, Pop3State *state)
                                    GINT_TO_POINTER(1));
        }
 
-       if ((msgnum = folder_item_add_msg(dropfolder, file)) < 0) {
+       if ((msgnum = folder_item_add_msg(dropfolder, file, TRUE)) < 0) {
                unlink(file);
                return -1;
        }
 
-       unlink(file);
-
        if (prefs_filtering != NULL) {
                /* new filtering */
                if (state->ac_prefs->filter_on_recv) {
index a5de8ef..7b30eef 100644 (file)
@@ -222,7 +222,7 @@ gint proc_mbox(FolderItem *dest, const gchar *mbox, GHashTable *folder_table)
                } else
                        dropfolder = dest;
 
-               if (msgnum =folder_item_add_msg(dropfolder, tmp_file) < 0) {
+               if (msgnum = folder_item_add_msg(dropfolder, tmp_file, TRUE) < 0) {
                        fclose(mbox_fp);
                        unlink(tmp_file);
                        return -1;
index bed1489..45cad37 100644 (file)
--- a/src/mh.c
+++ b/src/mh.c
@@ -26,6 +26,8 @@
 #include <glib.h>
 #include <dirent.h>
 #include <sys/stat.h>
+#include <unistd.h>
+#include <string.h>
 #include <errno.h>
 
 #undef MEASURE_TIME
@@ -128,7 +130,8 @@ gchar *mh_fetch_msg(Folder *folder, FolderItem *item, gint num)
        return file;
 }
 
-gint mh_add_msg(Folder *folder, FolderItem *dest, const gchar *file)
+gint mh_add_msg(Folder *folder, FolderItem *dest, const gchar *file,
+               gboolean remove_source)
 {
        gchar *destpath;
        gchar *destfile;
@@ -145,10 +148,25 @@ gint mh_add_msg(Folder *folder, FolderItem *dest, const gchar *file)
        g_return_val_if_fail(destpath != NULL, -1);
        destfile = g_strdup_printf("%s%c%d", destpath, G_DIR_SEPARATOR,
                                   dest->last_num + 1);
-       if (copy_file(file, destfile) < 0) {
-               g_warning(_("can't copy message %s to %s\n"), file, destfile);
-               g_free(destfile);
-               return -1;
+
+       if (link(file, destfile) < 0) {
+               if (EXDEV == errno) {
+                       if (copy_file(file, destfile) < 0) {
+                               g_warning(_("can't copy message %s to %s\n"),
+                                         file, destfile);
+                               g_free(destfile);
+                               return -1;
+                       }
+               } else {
+                       FILE_OP_ERROR(file, "link");
+                       g_free(destfile);
+                       return -1;
+               }
+       }
+
+       if (remove_source) {
+               if (unlink(file) < 0)
+                       FILE_OP_ERROR(file, "unlink");
        }
 
        g_free(destfile);
@@ -166,11 +184,6 @@ gint mh_move_msg(Folder *folder, FolderItem *dest, MsgInfo *msginfo)
        g_return_val_if_fail(dest != NULL, -1);
        g_return_val_if_fail(msginfo != NULL, -1);
 
-       if (!msginfo->folder) {
-               g_warning(_("the folder of the message is not defined\n"));
-               return -1;
-       }
-
        if (msginfo->folder == dest) {
                g_warning(_("the src folder is identical to the dest.\n"));
                return -1;
@@ -336,11 +349,6 @@ gint mh_copy_msg(Folder *folder, FolderItem *dest, MsgInfo *msginfo)
        g_return_val_if_fail(dest != NULL, -1);
        g_return_val_if_fail(msginfo != NULL, -1);
 
-       if (!msginfo->folder) {
-               g_warning(_("the folder of the message is not defined\n"));
-               return -1;
-       }
-
        if (msginfo->folder == dest) {
                g_warning(_("the src folder is identical to the dest.\n"));
                return -1;
index 05711ba..6467279 100644 (file)
--- a/src/mh.h
+++ b/src/mh.h
@@ -33,7 +33,8 @@ gchar   *mh_fetch_msg         (Folder         *folder,
                                 gint            num);
 gint     mh_add_msg            (Folder         *folder,
                                 FolderItem     *dest,
-                                const gchar    *file);
+                                const gchar    *file,
+                                gboolean        remove_source);
 gint     mh_move_msg           (Folder         *folder,
                                 FolderItem     *dest,
                                 MsgInfo        *msginfo);