aboutsummaryrefslogtreecommitdiffstats
path: root/mail/mail-vfolder.c
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2009-06-24 12:40:49 +0800
committerMatthew Barnes <mbarnes@redhat.com>2009-06-24 12:40:49 +0800
commit174c942e0945a2017f0c479883dce2950e42e786 (patch)
tree0011078b4121d5c6c200825b0ab1bb1c4cefd519 /mail/mail-vfolder.c
parentce7537b495a3788d9bda4b6a783a5c3d95309926 (diff)
downloadgsoc2013-evolution-174c942e0945a2017f0c479883dce2950e42e786.tar.gz
gsoc2013-evolution-174c942e0945a2017f0c479883dce2950e42e786.tar.zst
gsoc2013-evolution-174c942e0945a2017f0c479883dce2950e42e786.zip
Split store and local folder management out from shell backend.
Diffstat (limited to 'mail/mail-vfolder.c')
-rw-r--r--mail/mail-vfolder.c32
1 files changed, 15 insertions, 17 deletions
diff --git a/mail/mail-vfolder.c b/mail/mail-vfolder.c
index c018b9eea9..5a5f7324ed 100644
--- a/mail/mail-vfolder.c
+++ b/mail/mail-vfolder.c
@@ -50,6 +50,8 @@
#include "mail-tools.h"
#include "mail-vfolder.h"
+#include "e-mail-local.h"
+#include "e-mail-store.h"
#include "e-mail-shell-backend.h"
#define d(x) /* (printf("%s:%s: ", G_STRLOC, G_STRFUNC), (x))*/
@@ -339,26 +341,23 @@ uri_is_ignore(CamelStore *store, const gchar *uri)
EAccountList *accounts;
EAccount *account;
EIterator *iter;
- const gchar *local_drafts_folder_uri;
- const gchar *local_outbox_folder_uri;
- const gchar *local_sent_folder_uri;
+ const gchar *local_drafts_uri;
+ const gchar *local_outbox_uri;
+ const gchar *local_sent_uri;
gint found = FALSE;
- local_drafts_folder_uri = e_mail_shell_backend_get_folder_uri (
- global_mail_shell_backend, E_MAIL_FOLDER_DRAFTS);
- local_outbox_folder_uri = e_mail_shell_backend_get_folder_uri (
- global_mail_shell_backend, E_MAIL_FOLDER_OUTBOX);
- local_sent_folder_uri = e_mail_shell_backend_get_folder_uri (
- global_mail_shell_backend, E_MAIL_FOLDER_SENT);
+ local_drafts_uri = e_mail_local_get_folder_uri (E_MAIL_FOLDER_DRAFTS);
+ local_outbox_uri = e_mail_local_get_folder_uri (E_MAIL_FOLDER_OUTBOX);
+ local_sent_uri = e_mail_local_get_folder_uri (E_MAIL_FOLDER_SENT);
d(printf("checking '%s' against:\n %s\n %s\n %s\n", uri,
- local_outbox_folder_uri,
- local_sent_folder_uri,
- local_drafts_folder_uri));
+ local_outbox_uri,
+ local_sent_uri,
+ local_drafts_uri));
- found = camel_store_folder_uri_equal(store, local_outbox_folder_uri, uri)
- || camel_store_folder_uri_equal(store, local_sent_folder_uri, uri)
- || camel_store_folder_uri_equal(store, local_drafts_folder_uri, uri);
+ found = camel_store_folder_uri_equal(store, local_outbox_uri, uri)
+ || camel_store_folder_uri_equal(store, local_sent_uri, uri)
+ || camel_store_folder_uri_equal(store, local_drafts_uri, uri);
if (found)
return found;
@@ -987,8 +986,7 @@ vfolder_load_storage(void)
g_signal_connect(context, "rule_removed", G_CALLBACK(context_rule_removed), context);
/* load store to mail component */
- e_mail_shell_backend_load_store_by_uri (
- global_mail_shell_backend, storeuri, _("Search Folders"));
+ e_mail_store_add_by_uri (storeuri, _("Search Folders"));
/* and setup the rules we have */
rule = NULL;