aboutsummaryrefslogtreecommitdiffstats
path: root/mail/mail-send-recv.c
diff options
context:
space:
mode:
Diffstat (limited to 'mail/mail-send-recv.c')
-rw-r--r--mail/mail-send-recv.c24
1 files changed, 17 insertions, 7 deletions
diff --git a/mail/mail-send-recv.c b/mail/mail-send-recv.c
index 29cbb57322..9894ec2fa5 100644
--- a/mail/mail-send-recv.c
+++ b/mail/mail-send-recv.c
@@ -38,7 +38,6 @@
#include "camel/camel-store.h"
#include "mail-mt.h"
-#include "mail-component.h"
#include "mail-config.h"
#include "mail-session.h"
#include "mail-tools.h"
@@ -48,6 +47,8 @@
#include "em-event.h"
#include <e-util/gconf-bridge.h>
+#include "e-mail-shell-module.h"
+
#define d(x)
/* ms between status updates to the gui */
@@ -160,7 +161,8 @@ setup_send_data(void)
g_str_hash, g_str_equal,
(GDestroyNotify) NULL,
(GDestroyNotify) free_folder_info);
- data->inbox = mail_component_get_folder(NULL, MAIL_COMPONENT_FOLDER_LOCAL_INBOX);
+ data->inbox = e_mail_shell_module_get_folder (
+ mail_shell_module, E_MAIL_FOLDER_LOCAL_INBOX);
camel_object_ref(data->inbox);
data->active = g_hash_table_new_full (
g_str_hash, g_str_equal,
@@ -677,8 +679,13 @@ receive_done (char *uri, void *data)
/* if we've been called to run again - run again */
if (info->type == SEND_SEND && info->state == SEND_ACTIVE && info->again) {
+ CamelFolder *local_outbox_folder;
+
+ local_outbox_folder = e_mail_shell_module_get_folder (
+ mail_shell_module, E_MAIL_FOLDER_OUTBOX);
+
info->again = 0;
- mail_send_queue (mail_component_get_folder(NULL, MAIL_COMPONENT_FOLDER_OUTBOX),
+ mail_send_queue (local_outbox_folder,
info->uri,
FILTER_SOURCE_OUTGOING,
info->cancel,
@@ -890,7 +897,7 @@ receive_update_got_store (char *uri, CamelStore *store, void *data)
struct _send_info *info = data;
if (store) {
- mail_note_store(store, info->cancel, receive_update_got_folderinfo, info);
+ mail_note_store(mail_shell_module, store, info->cancel, receive_update_got_folderinfo, info);
} else {
receive_done("", info);
}
@@ -922,7 +929,8 @@ mail_send_receive (void)
accounts = mail_config_get_accounts ();
- outbox_folder = mail_component_get_folder(NULL, MAIL_COMPONENT_FOLDER_OUTBOX);
+ outbox_folder = e_mail_shell_module_get_folder (
+ mail_shell_module, E_MAIL_FOLDER_OUTBOX);
data = build_dialog (accounts, outbox_folder, account->transport->url);
scan = data->infos;
while (scan) {
@@ -1139,7 +1147,8 @@ mail_receive_uri (const char *uri, int keep)
break;
case SEND_SEND:
/* todo, store the folder in info? */
- outbox_folder = mail_component_get_folder(NULL, MAIL_COMPONENT_FOLDER_OUTBOX);
+ outbox_folder = e_mail_shell_module_get_folder (
+ mail_shell_module, E_MAIL_FOLDER_OUTBOX);
mail_send_queue (outbox_folder, info->uri,
FILTER_SOURCE_OUTGOING,
info->cancel,
@@ -1201,7 +1210,8 @@ mail_send (void)
g_hash_table_insert (data->active, SEND_URI_KEY, info);
/* todo, store the folder in info? */
- outbox_folder = mail_component_get_folder(NULL, MAIL_COMPONENT_FOLDER_OUTBOX);
+ outbox_folder = e_mail_shell_module_get_folder (
+ mail_shell_module, E_MAIL_FOLDER_OUTBOX);
mail_send_queue (outbox_folder, info->uri,
FILTER_SOURCE_OUTGOING,
info->cancel,