diff options
author | Not Zed <NotZed@Ximian.com> | 2004-02-04 13:57:21 +0800 |
---|---|---|
committer | Michael Zucci <zucchi@src.gnome.org> | 2004-02-04 13:57:21 +0800 |
commit | 956b17ed95a946949c51bfb6be9b4e358e764a45 (patch) | |
tree | be7b808f76bd99317588d4292a5812a19600d906 /camel/camel-vee-store.c | |
parent | 4d6ccba521e9413d1190cd946561be1991390dc3 (diff) | |
download | gsoc2013-evolution-956b17ed95a946949c51bfb6be9b4e358e764a45.tar.gz gsoc2013-evolution-956b17ed95a946949c51bfb6be9b4e358e764a45.tar.zst gsoc2013-evolution-956b17ed95a946949c51bfb6be9b4e358e764a45.zip |
changed order around, first try to delete and only remove from the object
2004-02-04 Not Zed <NotZed@Ximian.com>
* camel-store.c (camel_store_delete_folder): changed order around,
first try to delete and only remove from the object bag if the
delete worked. If vjunk/vtrash enabled, don't allow those to be
deleted.
(cs_delete_cached_folder): helper to delete the folder if its in
the cache, remove it from trash/junk, etc.
(camel_store_unsubscribe_folder): changed similarly to
delete_folder.
* camel-vee-store.c (vee_delete_folder): dont do any trash/junk
processing anymore.
2004-02-03 Not Zed <NotZed@Ximian.com>
* camel-store.c: use the folders object bag to manage the trash
folder and junk folders. Remove the init_trash and init_junk
stuff, just use get_trash and get_junk to mean the same thing.
Get rid of the hacked up vjunk and vtrash "uri" stuff too.
* camel-object.c (camel_object_bag_add): null out the pair->func,
otherwise we get an uninitalised memory read during unhook event.
svn path=/trunk/; revision=24603
Diffstat (limited to 'camel/camel-vee-store.c')
-rw-r--r-- | camel/camel-vee-store.c | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/camel/camel-vee-store.c b/camel/camel-vee-store.c index 20f39106b9..eb6c7ed214 100644 --- a/camel/camel-vee-store.c +++ b/camel/camel-vee-store.c @@ -35,9 +35,7 @@ static CamelFolder *vee_get_folder (CamelStore *store, const char *folder_name, guint32 flags, CamelException *ex); static void vee_delete_folder(CamelStore *store, const char *folder_name, CamelException *ex); static void vee_rename_folder(CamelStore *store, const char *old, const char *new, CamelException *ex); -static void vee_init_trash (CamelStore *store); static CamelFolder *vee_get_trash (CamelStore *store, CamelException *ex); -static void vee_init_junk (CamelStore *store); static CamelFolder *vee_get_junk (CamelStore *store, CamelException *ex); static CamelFolderInfo *vee_get_folder_info(CamelStore *store, const char *top, guint32 flags, CamelException *ex); @@ -80,9 +78,7 @@ camel_vee_store_class_init (CamelVeeStoreClass *klass) store_class->get_folder_info = vee_get_folder_info; store_class->free_folder_info = camel_store_free_folder_info_full; - store_class->init_trash = vee_init_trash; store_class->get_trash = vee_get_trash; - store_class->init_junk = vee_init_junk; store_class->get_junk = vee_get_junk; } @@ -187,26 +183,12 @@ vee_get_folder (CamelStore *store, const char *folder_name, guint32 flags, Camel return (CamelFolder *)vf; } -static void -vee_init_trash (CamelStore *store) -{ - /* no-op */ - ; -} - static CamelFolder * vee_get_trash (CamelStore *store, CamelException *ex) { return NULL; } -static void -vee_init_junk (CamelStore *store) -{ - /* no-op */ - ; -} - static CamelFolder * vee_get_junk (CamelStore *store, CamelException *ex) { @@ -363,13 +345,6 @@ vee_delete_folder(CamelStore *store, const char *folder_name, CamelException *ex folder = camel_object_bag_get(store->folders, folder_name); if (folder) { - camel_object_bag_remove(store->folders, folder); - - if (store->vtrash) - camel_vee_folder_remove_folder((CamelVeeFolder *)store->vtrash, folder); - if (store->vjunk) - camel_vee_folder_remove_folder((CamelVeeFolder *)store->vjunk, folder); - if ((((CamelVeeFolder *)folder)->flags & CAMEL_STORE_FOLDER_PRIVATE) == 0) { /* what about now-empty parents? ignore? */ change_folder(store, folder_name, CHANGE_DELETE, -1); |