aboutsummaryrefslogtreecommitdiffstats
path: root/mail/mail-local.c
diff options
context:
space:
mode:
author7 <NotZed@Ximian.com>2001-09-18 06:21:16 +0800
committerMichael Zucci <zucchi@src.gnome.org>2001-09-18 06:21:16 +0800
commit7796aa195e6ae1f3da3410d66a103145e10cd460 (patch)
tree6ffe2143ebe758f7124fec17248a939202b89ea9 /mail/mail-local.c
parentc8c0ecf1a7c718b8033f35c6cc41cab53e23c1e5 (diff)
downloadgsoc2013-evolution-7796aa195e6ae1f3da3410d66a103145e10cd460.tar
gsoc2013-evolution-7796aa195e6ae1f3da3410d66a103145e10cd460.tar.gz
gsoc2013-evolution-7796aa195e6ae1f3da3410d66a103145e10cd460.tar.bz2
gsoc2013-evolution-7796aa195e6ae1f3da3410d66a103145e10cd460.tar.lz
gsoc2013-evolution-7796aa195e6ae1f3da3410d66a103145e10cd460.tar.xz
gsoc2013-evolution-7796aa195e6ae1f3da3410d66a103145e10cd460.tar.zst
gsoc2013-evolution-7796aa195e6ae1f3da3410d66a103145e10cd460.zip
Setup global corba_storage variable. (mls_get_folder): Set 'update
2001-09-17 <NotZed@Ximian.com> * mail-local.c (storage_listener_startup): Setup global corba_storage variable. (mls_get_folder): Set 'update lstorage' on the newly opened folder. svn path=/trunk/; revision=12915
Diffstat (limited to 'mail/mail-local.c')
-rw-r--r--mail/mail-local.c18
1 files changed, 14 insertions, 4 deletions
diff --git a/mail/mail-local.c b/mail/mail-local.c
index c5b10fde0f..fdba26c128 100644
--- a/mail/mail-local.c
+++ b/mail/mail-local.c
@@ -56,7 +56,10 @@
#include "mail-folder-cache.h"
#include "mail-vfolder.h"
-#define d(x) x
+#define d(x)
+
+/* sigh, required for passing around to some functions */
+static GNOME_Evolution_Storage local_corba_storage = CORBA_OBJECT_NIL;
/* ** MailLocalStore ** (protos) ************************************************** */
@@ -636,9 +639,9 @@ mls_get_folder(CamelStore *store, const char *folder_name, guint32 flags, CamelE
{
MailLocalStore *local_store = MAIL_LOCAL_STORE (store);
MailLocalFolder *folder;
- char *physical_uri;
+ char *physical_uri, *name;
- d(printf("get_folder: %s", folder_name));
+ d(printf("--LOCAL-- get_folder: %s", folder_name));
folder = (MailLocalFolder *)camel_object_new(MAIL_LOCAL_FOLDER_TYPE);
folder = mail_local_folder_construct(folder, local_store, folder_name, ex);
@@ -663,6 +666,11 @@ mls_get_folder(CamelStore *store, const char *folder_name, guint32 flags, CamelE
/* FIXME: why is this here? */
physical_uri = g_strdup_printf("file://%s/%s", ((CamelService *)store)->url->path, folder_name);
mail_folder_cache_note_folder(physical_uri, CAMEL_FOLDER (folder));
+ name = strrchr(folder_name, '/');
+ if (name) /* should always be true... */ {
+ if (local_corba_storage != CORBA_OBJECT_NIL)
+ mail_folder_cache_set_update_lstorage(physical_uri, local_corba_storage, name);
+ }
g_free(physical_uri);
return (CamelFolder *)folder;
@@ -834,7 +842,9 @@ storage_listener_startup (EvolutionShellClient *shellclient)
GNOME_Evolution_Storage corba_storage;
CORBA_Environment ev;
- corba_storage = evolution_shell_client_get_local_storage (shellclient);
+ printf("---- CALLING STORAGE LISTENER STARTUP ---\n");
+
+ local_corba_storage = corba_storage = evolution_shell_client_get_local_storage (shellclient);
if (corba_storage == CORBA_OBJECT_NIL) {
g_warning ("No local storage available from shell client!");
return;