From 54b80a7271e8ce1b2f3ccc68bb553940a24b80e2 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Fri, 17 Oct 2008 03:48:03 +0000 Subject: Get the mail folder tree compiling, though I'm not yet sure why it's not showing anything. Probably something stupid. Also enabled the composer. svn path=/branches/kill-bonobo/; revision=36623 --- mail/mail-autofilter.c | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) (limited to 'mail/mail-autofilter.c') diff --git a/mail/mail-autofilter.c b/mail/mail-autofilter.c index af5f26093f..9ad44a6599 100644 --- a/mail/mail-autofilter.c +++ b/mail/mail-autofilter.c @@ -35,7 +35,6 @@ #include "mail-vfolder.h" #include "mail-autofilter.h" -#include "mail-component.h" #include "em-utils.h" #include "e-util/e-error.h" #include "e-util/e-util-private.h" @@ -52,6 +51,8 @@ #include #include +#include "e-mail-shell-module.h" + #define d(x) static void @@ -349,14 +350,15 @@ void filter_gui_add_from_message (CamelMimeMessage *msg, const char *source, int flags) { EMFilterContext *fc; + const gchar *data_dir; char *user, *system; FilterRule *rule; g_return_if_fail (msg != NULL); fc = em_filter_context_new (); - user = g_strdup_printf ("%s/filters.xml", - mail_component_peek_base_directory (mail_component_peek ())); + data_dir = e_shell_module_get_data_dir (mail_shell_module); + user = g_build_filename (data_dir, "filters.xml", NULL); system = g_build_filename (EVOLUTION_PRIVDATADIR, "filtertypes.xml", NULL); rule_context_load ((RuleContext *)fc, system, user); g_free (system); @@ -374,6 +376,7 @@ void mail_filter_rename_uri(CamelStore *store, const char *olduri, const char *newuri) { EMFilterContext *fc; + const gchar *data_dir; char *user, *system; GList *changed; char *eolduri, *enewuri; @@ -382,7 +385,8 @@ mail_filter_rename_uri(CamelStore *store, const char *olduri, const char *newuri enewuri = em_uri_from_camel(newuri); fc = em_filter_context_new (); - user = g_strdup_printf ("%s/filters.xml", mail_component_peek_base_directory (mail_component_peek ())); + data_dir = e_shell_module_get_data_dir (mail_shell_module); + user = g_build_filename (data_dir, "filters.xml", NULL); system = g_build_filename (EVOLUTION_PRIVDATADIR, "filtertypes.xml", NULL); rule_context_load ((RuleContext *)fc, system, user); g_free (system); @@ -406,6 +410,7 @@ void mail_filter_delete_uri(CamelStore *store, const char *uri) { EMFilterContext *fc; + const gchar *data_dir; char *user, *system; GList *deleted; char *euri; @@ -413,7 +418,8 @@ mail_filter_delete_uri(CamelStore *store, const char *uri) euri = em_uri_from_camel(uri); fc = em_filter_context_new (); - user = g_strdup_printf ("%s/filters.xml", mail_component_peek_base_directory (mail_component_peek ())); + data_dir = e_shell_module_get_data_dir (mail_shell_module); + user = g_build_filename (data_dir, "filters.xml", NULL); system = g_build_filename (EVOLUTION_PRIVDATADIR, "filtertypes.xml", NULL); rule_context_load ((RuleContext *)fc, system, user); g_free (system); -- cgit v1.2.3