diff options
author | Matthew Barnes <mbarnes@redhat.com> | 2011-05-12 12:50:29 +0800 |
---|---|---|
committer | Rodrigo Moya <rodrigo@gnome-db.org> | 2011-06-30 00:42:12 +0800 |
commit | 9c2e0cfad6867d75815c29648194bca657dd0aa6 (patch) | |
tree | a08b2016c865b3df873a9c2f5a53e61a393cf458 /mail | |
parent | 13e414debe58b6f8f2e97d58c581210cee065932 (diff) | |
download | gsoc2013-evolution-9c2e0cfad6867d75815c29648194bca657dd0aa6.tar gsoc2013-evolution-9c2e0cfad6867d75815c29648194bca657dd0aa6.tar.gz gsoc2013-evolution-9c2e0cfad6867d75815c29648194bca657dd0aa6.tar.bz2 gsoc2013-evolution-9c2e0cfad6867d75815c29648194bca657dd0aa6.tar.lz gsoc2013-evolution-9c2e0cfad6867d75815c29648194bca657dd0aa6.tar.xz gsoc2013-evolution-9c2e0cfad6867d75815c29648194bca657dd0aa6.tar.zst gsoc2013-evolution-9c2e0cfad6867d75815c29648194bca657dd0aa6.zip |
Remove mail_get_folder().
Use camel_store_get_folder() instead.
Diffstat (limited to 'mail')
-rw-r--r-- | mail/mail-ops.c | 79 | ||||
-rw-r--r-- | mail/mail-ops.h | 8 |
2 files changed, 0 insertions, 87 deletions
diff --git a/mail/mail-ops.c b/mail/mail-ops.c index a5210559a6..0a0f80fd93 100644 --- a/mail/mail-ops.c +++ b/mail/mail-ops.c @@ -1127,85 +1127,6 @@ mail_get_folderinfo (CamelStore *store, return id; } -/* ** LOAD FOLDER ********************************************************* */ - -/* there should be some way to merge this and create folder, since both can - presumably create a folder ... */ - -struct _get_folder_msg { - MailMsg base; - - EMailSession *session; - gchar *uri; - guint32 flags; - CamelFolder *folder; - void (*done) (gchar *uri, CamelFolder *folder, gpointer data); - gpointer data; -}; - -static gchar * -get_folder_desc (struct _get_folder_msg *m) -{ - return g_strdup_printf (_("Opening folder '%s'"), m->uri); -} - -static void -get_folder_exec (struct _get_folder_msg *m, - GCancellable *cancellable, - GError **error) -{ - m->folder = e_mail_session_uri_to_folder_sync ( - m->session, m->uri, m->flags, - cancellable, error); -} - -static void -get_folder_done (struct _get_folder_msg *m) -{ - if (m->done) - m->done (m->uri, m->folder, m->data); -} - -static void -get_folder_free (struct _get_folder_msg *m) -{ - g_object_unref (m->session); - g_free (m->uri); - if (m->folder) - g_object_unref (m->folder); -} - -static MailMsgInfo get_folder_info = { - sizeof (struct _get_folder_msg), - (MailMsgDescFunc) get_folder_desc, - (MailMsgExecFunc) get_folder_exec, - (MailMsgDoneFunc) get_folder_done, - (MailMsgFreeFunc) get_folder_free -}; - -gint -mail_get_folder (EMailSession *session, - const gchar *uri, - guint32 flags, - void (*done)(gchar *uri, CamelFolder *folder, gpointer data), - gpointer data, - MailMsgDispatchFunc dispatch) -{ - struct _get_folder_msg *m; - gint id; - - m = mail_msg_new (&get_folder_info); - m->session = g_object_ref (session); - m->uri = g_strdup (uri); - m->flags = flags; - m->data = data; - m->done = done; - - id = m->base.seq; - dispatch (m); - return id; -} - /* ** GET FOLDER'S QUOTA ********************************************************* */ struct _get_quota_msg { diff --git a/mail/mail-ops.h b/mail/mail-ops.h index f773c825f7..2ccea541aa 100644 --- a/mail/mail-ops.h +++ b/mail/mail-ops.h @@ -47,14 +47,6 @@ gint mail_get_message (CamelFolder *folder, const gchar *uid, gpointer data, MailMsgDispatchFunc dispatch); -/* same for a folder */ -gint mail_get_folder (EMailSession *session, - const gchar *uri, - guint32 flags, - void (*done) (gchar *uri, CamelFolder *folder, gpointer data), - gpointer data, - MailMsgDispatchFunc dispatch); - /* get quota information for a folder */ gint mail_get_folder_quota (CamelFolder *folder, const gchar *folder_uri, |