sync with sylpheed 0.7.2cvs17
[claws.git] / src / mh.c
index 2f91d432be266a78ea18bf38fdf20ea2299f5f35..f2bb0fb41101dff66b03081f37eefdfe82bfaf4e 100644 (file)
--- a/src/mh.c
+++ b/src/mh.c
@@ -740,9 +740,9 @@ void mh_scan_folder(Folder *folder, FolderItem *item)
        if (n_msg == 0)
                item->new = item->unread = item->total = 0;
        else {
-               gint new, unread, total;
+               gint new, unread, total, min, max;
 
-               procmsg_get_mark_sum(".", &new, &unread, &total);
+               procmsg_get_mark_sum(".", &new, &unread, &total, &min, &max, 0);
                if (n_msg > total) {
                        new += n_msg - total;
                        unread += n_msg - total;
@@ -1142,19 +1142,19 @@ static void mh_scan_tree_recursive(FolderItem *item, GHashTable *pptable)
                        new_item = folder_item_new(d->d_name, entry);
                        folder_item_append(item, new_item);
                        if (!item->path) {
-                               if (!strcmp(d->d_name, "inbox")) {
+                               if (!strcmp(d->d_name, INBOX_DIR)) {
                                        new_item->stype = F_INBOX;
                                        item->folder->inbox = new_item;
-                               } else if (!strcmp(d->d_name, "outbox")) {
+                               } else if (!strcmp(d->d_name, OUTBOX_DIR)) {
                                        new_item->stype = F_OUTBOX;
                                        item->folder->outbox = new_item;
-                               } else if (!strcmp(d->d_name, "draft")) {
+                               } else if (!strcmp(d->d_name, DRAFT_DIR)) {
                                        new_item->stype = F_DRAFT;
                                        item->folder->draft = new_item;
-                               } else if (!strcmp(d->d_name, "queue")) {
+                               } else if (!strcmp(d->d_name, QUEUE_DIR)) {
                                        new_item->stype = F_QUEUE;
                                        item->folder->queue = new_item;
-                               } else if (!strcmp(d->d_name, "trash")) {
+                               } else if (!strcmp(d->d_name, TRASH_DIR)) {
                                        new_item->stype = F_TRASH;
                                        item->folder->trash = new_item;
                                }
@@ -1169,9 +1169,10 @@ static void mh_scan_tree_recursive(FolderItem *item, GHashTable *pptable)
        closedir(dp);
 
        if (item->path) {
-               gint new, unread, total;
+               gint new, unread, total, min, max;
 
-               procmsg_get_mark_sum(item->path, &new, &unread, &total);
+               procmsg_get_mark_sum(item->path, &new, &unread, &total,
+                                    &min, &max, 0);
                if (n_msg > total) {
                        new += n_msg - total;
                        unread += n_msg - total;