* src/folder.c
authorChristoph Hohmann <reboot@gmx.ch>
Sat, 6 Jul 2002 01:07:26 +0000 (01:07 +0000)
committerChristoph Hohmann <reboot@gmx.ch>
Sat, 6 Jul 2002 01:07:26 +0000 (01:07 +0000)
* src/mainwindow.c
        fix folder_item_remove_all_msg and folderview
        status for trash folders after emptying trash

ChangeLog.claws
configure.in
src/folder.c
src/mainwindow.c

index f494654..7bf129c 100644 (file)
@@ -1,3 +1,10 @@
+2002-07-06 [christoph] 0.7.8claws49
+
+       * src/folder.c
+       * src/mainwindow.c
+               fix folder_item_remove_all_msg and folderview
+               status for trash folders after emptying trash
+
 2002-07-05 [paul]      0.7.8claws48
 
        * sync with 0.7.8cvs16
index ca0e5a0..884699f 100644 (file)
@@ -8,7 +8,7 @@ MINOR_VERSION=7
 MICRO_VERSION=8
 INTERFACE_AGE=0
 BINARY_AGE=0
-EXTRA_VERSION=claws48
+EXTRA_VERSION=claws49
 VERSION=$MAJOR_VERSION.$MINOR_VERSION.$MICRO_VERSION$EXTRA_VERSION
 
 dnl set $target
index f77cf8e..53caa2e 100644 (file)
@@ -1611,6 +1611,13 @@ gint folder_item_remove_all_msg(FolderItem *item)
        if (result == 0) {
                if (folder->finished_remove)
                        folder->finished_remove(folder, item);
+
+               folder_item_free_cache(item);
+               item->cache = msgcache_new();
+
+               item->new = 0;
+               item->unread = 0;
+               item->total = 0;
        }
 
        return result;
index 04582ce..3c27ed0 100644 (file)
@@ -1436,7 +1436,7 @@ void main_window_empty_trash(MainWindow *mainwin, gboolean confirm)
 
        for (list = folder_get_list(); list != NULL; list = list->next) {
                folder = list->data;
-               if (folder && folder->trash && folder->trash->total != 0) {
+               if (folder && folder->trash) {
                        folderview_update_item(folder->trash, TRUE);
                }
        }