aboutsummaryrefslogtreecommitdiffstats
path: root/mail/mail-ops.c
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2010-10-31 02:23:01 +0800
committerRodrigo Moya <rodrigo@gnome-db.org>2010-11-10 06:33:19 +0800
commit58727dbb22ceeaf950ba7931fd516b112689b5a6 (patch)
tree4a013e3a33478cd0c6298cb54e47b09158264959 /mail/mail-ops.c
parent63057a9a602ce6fb195275ca8ede0244261ad926 (diff)
downloadgsoc2013-evolution-58727dbb22ceeaf950ba7931fd516b112689b5a6.tar
gsoc2013-evolution-58727dbb22ceeaf950ba7931fd516b112689b5a6.tar.gz
gsoc2013-evolution-58727dbb22ceeaf950ba7931fd516b112689b5a6.tar.bz2
gsoc2013-evolution-58727dbb22ceeaf950ba7931fd516b112689b5a6.tar.lz
gsoc2013-evolution-58727dbb22ceeaf950ba7931fd516b112689b5a6.tar.xz
gsoc2013-evolution-58727dbb22ceeaf950ba7931fd516b112689b5a6.tar.zst
gsoc2013-evolution-58727dbb22ceeaf950ba7931fd516b112689b5a6.zip
Kill mail_append_mail().
Use e_mail_folder_append_message() instead.
Diffstat (limited to 'mail/mail-ops.c')
-rw-r--r--mail/mail-ops.c86
1 files changed, 0 insertions, 86 deletions
diff --git a/mail/mail-ops.c b/mail/mail-ops.c
index ffaa7e41af..ccbd934fe7 100644
--- a/mail/mail-ops.c
+++ b/mail/mail-ops.c
@@ -919,92 +919,6 @@ mail_send_queue (EMailSession *session,
mail_msg_unordered_push (m);
}
-/* ** APPEND MESSAGE TO FOLDER ******************************************** */
-
-struct _append_msg {
- MailMsg base;
-
- CamelFolder *folder;
- CamelMimeMessage *message;
- CamelMessageInfo *info;
- gchar *appended_uid;
-
- void (*done)(CamelFolder *folder, CamelMimeMessage *msg, CamelMessageInfo *info, gint ok, const gchar *appended_uid, gpointer data);
- gpointer data;
-};
-
-static gchar *
-append_mail_desc (struct _append_msg *m)
-{
- return g_strdup_printf (_("Saving message to folder '%s'"), camel_folder_get_full_name (m->folder));
-}
-
-static void
-append_mail_exec (struct _append_msg *m,
- GCancellable *cancellable,
- GError **error)
-{
- camel_mime_message_set_date (
- m->message, CAMEL_MESSAGE_DATE_CURRENT, 0);
-
- camel_folder_append_message_sync (
- m->folder, m->message,
- m->info, &m->appended_uid,
- cancellable, error);
-}
-
-static void
-append_mail_done (struct _append_msg *m)
-{
- if (m->done)
- m->done (
- m->folder, m->message,
- m->info, m->base.error == NULL,
- m->appended_uid, m->data);
-}
-
-static void
-append_mail_free (struct _append_msg *m)
-{
- g_object_unref (m->message);
- g_object_unref (m->folder);
- g_free (m->appended_uid);
-}
-
-static MailMsgInfo append_mail_info = {
- sizeof (struct _append_msg),
- (MailMsgDescFunc) append_mail_desc,
- (MailMsgExecFunc) append_mail_exec,
- (MailMsgDoneFunc) append_mail_done,
- (MailMsgFreeFunc) append_mail_free
-};
-
-void
-mail_append_mail (CamelFolder *folder, CamelMimeMessage *message, CamelMessageInfo *info,
- void (*done)(CamelFolder *folder, CamelMimeMessage *msg, CamelMessageInfo *info, gint ok, const gchar *appended_uid, gpointer data),
- gpointer data)
-{
- struct _append_msg *m;
-
- g_return_if_fail (CAMEL_IS_FOLDER (folder));
- g_return_if_fail (CAMEL_IS_MIME_MESSAGE (message));
-
- if (!camel_medium_get_header (CAMEL_MEDIUM (message), "X-Mailer"))
- camel_medium_set_header (CAMEL_MEDIUM (message), "X-Mailer", x_mailer);
-
- m = mail_msg_new (&append_mail_info);
- m->folder = folder;
- g_object_ref (folder);
- m->message = message;
- g_object_ref (message);
- m->info = info;
-
- m->done = done;
- m->data = data;
-
- mail_msg_unordered_push (m);
-}
-
/* ** TRANSFER MESSAGES **************************************************** */
struct _transfer_msg {