aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--mail/mail-ops.c79
-rw-r--r--mail/mail-ops.h6
2 files changed, 0 insertions, 85 deletions
diff --git a/mail/mail-ops.c b/mail/mail-ops.c
index 0a0f80fd93..e57b63445e 100644
--- a/mail/mail-ops.c
+++ b/mail/mail-ops.c
@@ -1802,85 +1802,6 @@ mail_empty_trash (EMailSession *session,
mail_msg_slow_ordered_push (m);
}
-/* ** GET MESSAGE(s) ***************************************************** */
-
-struct _get_message_msg {
- MailMsg base;
-
- CamelFolder *folder;
- gchar *uid;
- void (*done) (CamelFolder *folder, const gchar *uid, CamelMimeMessage *msg, gpointer data);
- gpointer data;
- CamelMimeMessage *message;
- GCancellable *cancellable;
-};
-
-static gchar *
-get_message_desc (struct _get_message_msg *m)
-{
- return g_strdup_printf (_("Retrieving message '%s'"), m->uid);
-}
-
-static void
-get_message_exec (struct _get_message_msg *m,
- GCancellable *cancellable,
- GError **error)
-{
- if (g_cancellable_is_cancelled (cancellable))
- m->message = NULL;
- else
- m->message = camel_folder_get_message_sync (
- m->folder, m->uid, cancellable, error);
-}
-
-static void
-get_message_done (struct _get_message_msg *m)
-{
- if (m->done)
- m->done (m->folder, m->uid, m->message, m->data);
-}
-
-static void
-get_message_free (struct _get_message_msg *m)
-{
- g_free (m->uid);
- g_object_unref (m->folder);
- g_object_unref (m->cancellable);
-
- if (m->message)
- g_object_unref (m->message);
-}
-
-static MailMsgInfo get_message_info = {
- sizeof (struct _get_message_msg),
- (MailMsgDescFunc) get_message_desc,
- (MailMsgExecFunc) get_message_exec,
- (MailMsgDoneFunc) get_message_done,
- (MailMsgFreeFunc) get_message_free
-};
-
-gint
-mail_get_message (CamelFolder *folder, const gchar *uid, void (*done) (CamelFolder *folder, const gchar *uid,
- CamelMimeMessage *msg, gpointer data),
- gpointer data, MailMsgDispatchFunc dispatch)
-{
- struct _get_message_msg *m;
- gint id;
-
- m = mail_msg_new (&get_message_info);
- m->folder = folder;
- g_object_ref (folder);
- m->uid = g_strdup (uid);
- m->data = data;
- m->done = (void (*) (CamelFolder *, const gchar *, CamelMimeMessage *, gpointer )) done;
- m->cancellable = camel_operation_new ();
- id = m->base.seq;
-
- dispatch (m);
-
- return id;
-}
-
/* ** SAVE MESSAGES ******************************************************* */
struct _save_messages_msg {
diff --git a/mail/mail-ops.h b/mail/mail-ops.h
index 2ccea541aa..8478595b17 100644
--- a/mail/mail-ops.h
+++ b/mail/mail-ops.h
@@ -41,12 +41,6 @@ void mail_transfer_messages (EMailSession *session,
void (*done) (gboolean ok, gpointer data),
gpointer data);
-/* get a single message, asynchronously */
-gint mail_get_message (CamelFolder *folder, const gchar *uid,
- void (*done) (CamelFolder *folder, const gchar *uid, CamelMimeMessage *msg, gpointer data),
- gpointer data,
- MailMsgDispatchFunc dispatch);
-
/* get quota information for a folder */
gint mail_get_folder_quota (CamelFolder *folder,
const gchar *folder_uri,