diff options
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/exchange-operations/ChangeLog | 7 | ||||
-rw-r--r-- | plugins/exchange-operations/exchange-folder.c | 2 | ||||
-rw-r--r-- | plugins/folder-unsubscribe/ChangeLog | 7 | ||||
-rw-r--r-- | plugins/folder-unsubscribe/folder-unsubscribe.c | 41 | ||||
-rw-r--r-- | plugins/groupwise-features/share-folder-common.c | 40 | ||||
-rw-r--r-- | plugins/itip-formatter/ChangeLog | 7 | ||||
-rw-r--r-- | plugins/itip-formatter/itip-formatter.c | 33 | ||||
-rw-r--r-- | plugins/mailing-list-actions/ChangeLog | 5 | ||||
-rw-r--r-- | plugins/mailing-list-actions/mailing-list-actions.c | 2 | ||||
-rw-r--r-- | plugins/mark-all-read/ChangeLog | 7 | ||||
-rw-r--r-- | plugins/mark-all-read/mark-all-read.c | 2 | ||||
-rw-r--r-- | plugins/save-attachments/ChangeLog | 7 | ||||
-rw-r--r-- | plugins/save-attachments/save-attachments.c | 2 |
13 files changed, 92 insertions, 70 deletions
diff --git a/plugins/exchange-operations/ChangeLog b/plugins/exchange-operations/ChangeLog index bdf2c34b6f..2e4510aa08 100644 --- a/plugins/exchange-operations/ChangeLog +++ b/plugins/exchange-operations/ChangeLog @@ -1,3 +1,10 @@ +2007-12-20 Matthew Barnes <mbarnes@redhat.com> + + ** Fixes part of bug #362638 + + * exchange_folder.c: + Use the new MailMsg API for messages. + 2007-12-13 Tobias Mueller <tobiasmue@svn.gnome.org> Patch by evilninjasquirrel@hotbrev.com diff --git a/plugins/exchange-operations/exchange-folder.c b/plugins/exchange-operations/exchange-folder.c index 879e4ded28..e7a877c103 100644 --- a/plugins/exchange-operations/exchange-folder.c +++ b/plugins/exchange-operations/exchange-folder.c @@ -140,7 +140,7 @@ org_gnome_exchange_folder_inbox_unsubscribe (EPopup *ep, EPopupItem *p, void *da inbox_physical_uri = e_folder_get_physical_uri (inbox); /* To get the CamelStore/Folder */ - mail_get_folder (inbox_physical_uri, 0, exchange_get_folder, target_uri, mail_thread_new); + mail_get_folder (inbox_physical_uri, 0, exchange_get_folder, target_uri, mail_msg_unordered_push); } diff --git a/plugins/folder-unsubscribe/ChangeLog b/plugins/folder-unsubscribe/ChangeLog index 909ad22d46..db584a1e04 100644 --- a/plugins/folder-unsubscribe/ChangeLog +++ b/plugins/folder-unsubscribe/ChangeLog @@ -1,3 +1,10 @@ +2007-12-20 Matthew Barnes <mbarnes@redhat.com> + + ** Fixes part of bug #362638 + + * folder-unsubscribe.c: + Use the new MailMsg API for messages. + 2007-11-18 Gilles Dartiguelongue <gdartigu@svn.gnome.org> ** Fix bug #495875 diff --git a/plugins/folder-unsubscribe/folder-unsubscribe.c b/plugins/folder-unsubscribe/folder-unsubscribe.c index 227da31ec1..86d2e6aec6 100644 --- a/plugins/folder-unsubscribe/folder-unsubscribe.c +++ b/plugins/folder-unsubscribe/folder-unsubscribe.c @@ -44,56 +44,53 @@ void org_gnome_mail_folder_unsubscribe (EPlugin *plug, EMPopupTargetFolder *targ struct _folder_unsub_t { - struct _mail_msg msg; + MailMsg base; char *uri; }; -static char * -folder_unsubscribe__desc (struct _mail_msg *mm, int done) +static gchar * +folder_unsubscribe_desc (struct _folder_unsub_t *msg) { - struct _folder_unsub_t *unsub = (struct _folder_unsub_t *) mm; - - return g_strdup_printf (_("Unsubscribing from folder \"%s\""), unsub->uri); + return g_strdup_printf ( + _("Unsubscribing from folder \"%s\""), msg->uri); } static void -folder_unsubscribe__unsub (struct _mail_msg *mm) +folder_unsubscribe_exec (struct _folder_unsub_t *msg) { - struct _folder_unsub_t *unsub = (struct _folder_unsub_t *) mm; extern CamelSession *session; const char *path = NULL; CamelStore *store; CamelURL *url; - if (!(store = camel_session_get_store (session, unsub->uri, &mm->ex))) + if (!(store = camel_session_get_store (session, msg->uri, &msg->base.ex))) return; - url = camel_url_new (unsub->uri, NULL); + url = camel_url_new (msg->uri, NULL); if (((CamelService *) store)->provider->url_flags & CAMEL_URL_FRAGMENT_IS_PATH) path = url->fragment; else if (url->path && url->path[0]) path = url->path + 1; if (path != NULL) - camel_store_unsubscribe_folder (store, path, &mm->ex); + camel_store_unsubscribe_folder (store, path, &msg->base.ex); camel_url_free (url); } static void -folder_unsubscribe__free (struct _mail_msg *mm) +folder_unsubscribe_free (struct _folder_unsub_t *msg) { - struct _folder_unsub_t *unsub = (struct _folder_unsub_t *) mm; - - g_free (unsub->uri); + g_free (msg->uri); } -static struct _mail_msg_op unsubscribe_op = { - folder_unsubscribe__desc, - folder_unsubscribe__unsub, - NULL, - folder_unsubscribe__free, +static MailMsgInfo unsubscribe_info = { + sizeof (struct _folder_unsub_t), + (MailMsgDescFunc) folder_unsubscribe_desc, + (MailMsgExecFunc) folder_unsubscribe_exec, + (MailMsgDoneFunc) NULL, + (MailMsgFreeFunc) folder_unsubscribe_free }; @@ -105,8 +102,8 @@ org_gnome_mail_folder_unsubscribe (EPlugin *plug, EMPopupTargetFolder *target) if (target->uri == NULL) return; - unsub = mail_msg_new (&unsubscribe_op, NULL, sizeof (struct _folder_unsub_t)); + unsub = mail_msg_new (&unsubscribe_info); unsub->uri = g_strdup (target->uri); - e_thread_put (mail_thread_new, (EMsg *) unsub); + mail_msg_unordered_push (unsub); } diff --git a/plugins/groupwise-features/share-folder-common.c b/plugins/groupwise-features/share-folder-common.c index 20acd894d4..952980b171 100644 --- a/plugins/groupwise-features/share-folder-common.c +++ b/plugins/groupwise-features/share-folder-common.c @@ -121,7 +121,7 @@ shared_folder_abort (EPlugin *ep, EConfigTarget *target) } struct _EMCreateFolder { - struct _mail_msg msg; + MailMsg base; /* input data */ CamelStore *store; @@ -137,31 +137,26 @@ struct _EMCreateFolder { void *user_data; }; -static char * -create_folder__desc (struct _mail_msg *mm, int done) +static gchar * +create_folder_desc (struct _EMCreateFolder *m) { - struct _EMCreateFolder *m = (struct _EMCreateFolder *) mm; - return g_strdup_printf (_("Creating folder `%s'"), m->full_name); } static void -create_folder__create (struct _mail_msg *mm) +create_folder_exec (struct _EMCreateFolder *m) { - struct _EMCreateFolder *m = (struct _EMCreateFolder *) mm; - d(printf ("creating folder parent='%s' name='%s' full_name='%s'\n", m->parent, m->name, m->full_name)); - if ((m->fi = camel_store_create_folder (m->store, m->parent, m->name, &mm->ex))) { + if ((m->fi = camel_store_create_folder (m->store, m->parent, m->name, &m->base.ex))) { if (camel_store_supports_subscriptions (m->store)) - camel_store_subscribe_folder (m->store, m->full_name, &mm->ex); + camel_store_subscribe_folder (m->store, m->full_name, &m->base.ex); } } static void -create_folder__created (struct _mail_msg *mm) +create_folder_done (struct _EMCreateFolder *m) { - struct _EMCreateFolder *m = (struct _EMCreateFolder *) mm; struct ShareInfo *ssi = (struct ShareInfo *) m->user_data; CamelStore *store = CAMEL_STORE (m->store) ; EGwConnection *ccnc; @@ -180,10 +175,8 @@ create_folder__created (struct _mail_msg *mm) } static void -create_folder__free (struct _mail_msg *mm) +create_folder_free (struct _EMCreateFolder *m) { - struct _EMCreateFolder *m = (struct _EMCreateFolder *) mm; - camel_store_free_folder_info (m->store, m->fi); camel_object_unref (m->store); g_free (m->full_name); @@ -191,11 +184,12 @@ create_folder__free (struct _mail_msg *mm) g_free (m->name); } -static struct _mail_msg_op create_folder_op = { - create_folder__desc, - create_folder__create, - create_folder__created, - create_folder__free, +static MailMsgInfo create_folder_info = { + sizeof (struct _EMCreateFolder), + (MailMsgDescFunc) create_folder_desc, + (MailMsgExecFunc) create_folder_exec, + (MailMsgDoneFunc) create_folder_done, + (MailMsgFreeFunc) create_folder_free }; static void @@ -229,7 +223,7 @@ create_folder (CamelStore *store, const char *full_name, void (* done) (struct _ parent = namebuf; } - m = mail_msg_new (&create_folder_op, NULL, sizeof (struct _EMCreateFolder)); + m = mail_msg_new (&create_folder_info); camel_object_ref (store); m->store = store; m->full_name = g_strdup (full_name); @@ -238,8 +232,8 @@ create_folder (CamelStore *store, const char *full_name, void (* done) (struct _ m->user_data = (struct ShareInfo *) user_data; m->done = done; g_free (namebuf); - id = m->msg.seq; - e_thread_put (mail_thread_new, (EMsg *) m); + id = m->base.seq; + mail_msg_unordered_push (m); return id; } diff --git a/plugins/itip-formatter/ChangeLog b/plugins/itip-formatter/ChangeLog index d4132aeb8f..cc9f039bfd 100644 --- a/plugins/itip-formatter/ChangeLog +++ b/plugins/itip-formatter/ChangeLog @@ -1,3 +1,10 @@ +2007-12-20 Matthew Barnes <mbarnes@redhat.com> + + ** Fixes part of bug #362638 + + * itip-formatter.c: + Use the new MailMsg API for messages. + 2007-12-04 Milan Crha <mcrha@redhat.com> ** Fix for bug #220846 diff --git a/plugins/itip-formatter/itip-formatter.c b/plugins/itip-formatter/itip-formatter.c index a3bb6c2e80..bd62118d40 100644 --- a/plugins/itip-formatter/itip-formatter.c +++ b/plugins/itip-formatter/itip-formatter.c @@ -1551,47 +1551,38 @@ extract_itip_data (FormatItipPObject *pitip, GtkContainer *container) } struct _opencal_msg { - struct _mail_msg msg; + MailMsg base; char *command; /* command line to run */ }; static char * -open_calendar_desc (struct _mail_msg *mm, int done) +open_calendar__desc (struct _opencal_msg *m, gint complete) { return g_strdup (_("Opening calendar")); } static void -open_calendar_do (struct _mail_msg *mm) +open_calendar__exec (struct _opencal_msg *m) { - struct _opencal_msg *m = (struct _opencal_msg *)mm; - if (!g_spawn_command_line_async (m->command, NULL)) { g_warning ("Could not launch %s", m->command); } } static void -open_calendar_done (struct _mail_msg *mm) -{ - /*struct _opencal_msg *m = (struct _opencal_msg *)mm;*/ -} - -static void -open_calendar_free (struct _mail_msg *mm) +open_calendar__free (struct _opencal_msg *m) { - struct _opencal_msg *m = (struct _opencal_msg *)mm; - g_free (m->command); m->command = NULL; } -static struct _mail_msg_op open_calendar_op = { - open_calendar_desc, - open_calendar_do, - open_calendar_done, - open_calendar_free, +static MailMsgInfo open_calendar_info = { + sizeof (struct _opencal_msg), + (MailMsgDescFunc) open_calendar__desc, + (MailMsgExecFunc) open_calendar__exec, + (MailMsgDoneFunc) NULL, + (MailMsgFreeFunc) open_calendar__free, }; static gboolean @@ -1600,10 +1591,10 @@ idle_open_cb (gpointer data) FormatItipPObject *pitip = data; struct _opencal_msg *m; - m = mail_msg_new (&open_calendar_op, NULL, sizeof (*m)); + m = mail_msg_new (&open_calendar_info); m->command = g_strdup_printf ("evolution \"calendar://?startdate=%s&enddate=%s\"", isodate_from_time_t (pitip->start_time), isodate_from_time_t (pitip->end_time)); - e_thread_put (mail_thread_queued_slow, (EMsg *)m); + mail_msg_slow_ordered_push (m); return FALSE; } diff --git a/plugins/mailing-list-actions/ChangeLog b/plugins/mailing-list-actions/ChangeLog index 3d8e2ffd78..acb68eba4c 100644 --- a/plugins/mailing-list-actions/ChangeLog +++ b/plugins/mailing-list-actions/ChangeLog @@ -1,3 +1,8 @@ +2007-12-20 Matthew Barnes <mbarnes@redhat.com> + + * mailing-list-actions.c: + Use the new MailMsg API for messages. + 2007-04-02 Sankar P <psankar@novell.com> * Committed on behalf of Gilles Dartiguelongue <dartigug@esiee.fr> diff --git a/plugins/mailing-list-actions/mailing-list-actions.c b/plugins/mailing-list-actions/mailing-list-actions.c index f872a0e983..1ffea79954 100644 --- a/plugins/mailing-list-actions/mailing-list-actions.c +++ b/plugins/mailing-list-actions/mailing-list-actions.c @@ -89,7 +89,7 @@ void emla_list_action (EPlugin *item, EMMenuTargetSelect* sel, EmlaAction action data->uri = strdup (sel->uri); mail_get_message (sel->folder, (const char*) g_ptr_array_index (sel->uids, 0), - emla_list_action_do, data, mail_thread_new); + emla_list_action_do, data, mail_msg_unordered_push); } void emla_list_action_do (CamelFolder *folder, const char *uid, CamelMimeMessage *msg, void *data) diff --git a/plugins/mark-all-read/ChangeLog b/plugins/mark-all-read/ChangeLog index ce35ebf76e..c53c809458 100644 --- a/plugins/mark-all-read/ChangeLog +++ b/plugins/mark-all-read/ChangeLog @@ -1,3 +1,10 @@ +2007-12-20 Matthew Barnes <mbarnes@redhat.com> + + ** Fixes part of bug #362638 + + * mark-all-read.c: + Use the new MailMsg API for messages. + 2007-11-18 Gilles Dartiguelongue <gdartigu@svn.gnome.org> ** Fix bug #495875 diff --git a/plugins/mark-all-read/mark-all-read.c b/plugins/mark-all-read/mark-all-read.c index e766d45df5..7e01b3f79a 100644 --- a/plugins/mark-all-read/mark-all-read.c +++ b/plugins/mark-all-read/mark-all-read.c @@ -44,7 +44,7 @@ org_gnome_mark_all_read (EPlugin *ep, EMPopupTargetFolder *t) return; } - mail_get_folder(t->uri, 0, mar_got_folder, NULL, mail_thread_new); + mail_get_folder(t->uri, 0, mar_got_folder, NULL, mail_msg_unordered_push); } static void diff --git a/plugins/save-attachments/ChangeLog b/plugins/save-attachments/ChangeLog index fb0d2426d3..6f27566f57 100644 --- a/plugins/save-attachments/ChangeLog +++ b/plugins/save-attachments/ChangeLog @@ -1,3 +1,10 @@ +2007-12-20 Matthew Barnes <mbarnes@redhat.com> + + ** Fixes part of bug #362638 + + * save-attachments.c: + Use the new MailMsg API for messages. + 2007-04-02 Sankar P <psankar@novell.com> * Committed on behalf of Gilles Dartiguelongue <dartigug@esiee.fr> diff --git a/plugins/save-attachments/save-attachments.c b/plugins/save-attachments/save-attachments.c index 269a9e95c7..c1d8646c2a 100644 --- a/plugins/save-attachments/save-attachments.c +++ b/plugins/save-attachments/save-attachments.c @@ -403,5 +403,5 @@ org_gnome_save_attachments_save(EPlugin *ep, EMMenuTargetSelect *target) camel_object_ref(data->folder); data->uid = g_strdup(target->uids->pdata[0]); - mail_get_message(data->folder, data->uid, save_got_message, data, mail_thread_new); + mail_get_message(data->folder, data->uid, save_got_message, data, mail_msg_unordered_push); } |