aboutsummaryrefslogtreecommitdiffstats
path: root/camel/providers/MH/camel-mh-folder.c
diff options
context:
space:
mode:
authorbertrand <Bertrand.Guiheneuf@aful.org>1999-09-08 07:08:03 +0800
committerBertrand Guiheneuf <bertrand@src.gnome.org>1999-09-08 07:08:03 +0800
commited7fc1eaa25aaa22652279986a994869fd1d6445 (patch)
treed1bc3b749189941f03b0cc616a8a21dbb55b5018 /camel/providers/MH/camel-mh-folder.c
parentdba244cf65b620c514c94ffc3165836c28002a29 (diff)
downloadgsoc2013-evolution-ed7fc1eaa25aaa22652279986a994869fd1d6445.tar
gsoc2013-evolution-ed7fc1eaa25aaa22652279986a994869fd1d6445.tar.gz
gsoc2013-evolution-ed7fc1eaa25aaa22652279986a994869fd1d6445.tar.bz2
gsoc2013-evolution-ed7fc1eaa25aaa22652279986a994869fd1d6445.tar.lz
gsoc2013-evolution-ed7fc1eaa25aaa22652279986a994869fd1d6445.tar.xz
gsoc2013-evolution-ed7fc1eaa25aaa22652279986a994869fd1d6445.tar.zst
gsoc2013-evolution-ed7fc1eaa25aaa22652279986a994869fd1d6445.zip
More work on UID list in Mh provider.
1999-09-08 bertrand <Bertrand.Guiheneuf@aful.org> * tests/ui-tests/store_listing.c (close_all): close all open folders and stores. (necessary for UID list saving ). * camel/providers/MH/mh-uid.c (mh_generate_uid_list): fix: store UID list in CamelMHFolder object. * camel/providers/MH/camel-mh-folder.c (_open): read or create UID list. (_close): save UID list. svn path=/trunk/; revision=1192
Diffstat (limited to 'camel/providers/MH/camel-mh-folder.c')
-rw-r--r--camel/providers/MH/camel-mh-folder.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/camel/providers/MH/camel-mh-folder.c b/camel/providers/MH/camel-mh-folder.c
index 272090fa0e..1afc441cad 100644
--- a/camel/providers/MH/camel-mh-folder.c
+++ b/camel/providers/MH/camel-mh-folder.c
@@ -62,6 +62,7 @@ static gint _append_message (CamelFolder *folder, CamelMimeMessage *message);
static void _expunge (CamelFolder *folder);
static void _copy_message_to (CamelFolder *folder, CamelMimeMessage *message, CamelFolder *dest_folder);
static void _open (CamelFolder *folder, CamelFolderOpenMode mode);
+static void _close (CamelFolder *folder, gboolean expunge);
/* some utility functions */
@@ -88,6 +89,7 @@ camel_mh_folder_class_init (CamelMhFolderClass *camel_mh_folder_class)
camel_folder_class->expunge = _expunge;
camel_folder_class->copy_message_to = _copy_message_to;
camel_folder_class->open = _open;
+ camel_folder_class->close = _close;
}
@@ -235,7 +237,7 @@ _open (CamelFolder *folder, CamelFolderOpenMode mode)
_create_summary (folder);
/* get (or create) uid list */
- if (!mh_load_uid_list (mh_folder))
+ if (!(mh_load_uid_list (mh_folder) > 0))
mh_generate_uid_list (mh_folder);
}
@@ -245,10 +247,9 @@ static void
_close (CamelFolder *folder, gboolean expunge)
{
CamelMhFolder *mh_folder = CAMEL_MH_FOLDER (folder);
-
if (mh_folder->uid_array)
mh_save_uid_list (mh_folder);
-
+
/* call parent implementation */
parent_class->close (folder, expunge);
}