From 16eefad8858f0821257487aa1a6ac970708fd972 Mon Sep 17 00:00:00 2001 From: Not Zed Date: Thu, 19 May 2005 06:06:35 +0000 Subject: fix rodney's name choices. fix multiple-inclusion. fix forward references. 2005-05-19 Not Zed * em-folder-utils.h: fix rodney's name choices. fix multiple-inclusion. fix forward references. fix all callers. add many fixme's for the busted api's. * em-format-quote.c (emfq_format_clone): use pseudo mime type to find message formatter. * em-format-html-display.c (efhd_format_message): remove, it didn't do anything. * em-format-html.c (efh_format_message): make this a handler callback. * em-format.c (emf_message_rfc822): make this use the pseudo mime-type x-evolution/message/rfc822 instead of the hardcoded format_message callback. * em-format-html-display.c (efhd_message_prefix): make this use a pseudo-mime-type handler rather than hard-coded, so it can be overridden by a plugin. svn path=/trunk/; revision=29382 --- mail/em-format-html-display.c | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) (limited to 'mail/em-format-html-display.c') diff --git a/mail/em-format-html-display.c b/mail/em-format-html-display.c index 0bf61bd145..c835dd1541 100644 --- a/mail/em-format-html-display.c +++ b/mail/em-format-html-display.c @@ -125,11 +125,11 @@ static void efhd_iframe_created(GtkHTML *html, GtkHTML *iframe, EMFormatHTMLDisp /*static void efhd_url_requested(GtkHTML *html, const char *url, GtkHTMLStream *handle, EMFormatHTMLDisplay *efh); static gboolean efhd_object_requested(GtkHTML *html, GtkHTMLEmbedded *eb, EMFormatHTMLDisplay *efh);*/ +static void efhd_message_prefix(EMFormat *emf, CamelStream *stream, CamelMimePart *part, EMFormatHandler *info); + static const EMFormatHandler *efhd_find_handler(EMFormat *emf, const char *mime_type); static void efhd_format_clone(EMFormat *, CamelFolder *folder, const char *, CamelMimeMessage *msg, EMFormat *); -static void efhd_format_prefix(EMFormat *emf, CamelStream *stream); static void efhd_format_error(EMFormat *emf, CamelStream *stream, const char *txt); -static void efhd_format_message(EMFormat *, CamelStream *, CamelMedium *); static void efhd_format_source(EMFormat *, CamelStream *, CamelMimePart *); static void efhd_format_attachment(EMFormat *, CamelStream *, CamelMimePart *, const char *, const EMFormatHandler *); static void efhd_format_secure(EMFormat *emf, CamelStream *stream, CamelMimePart *part, CamelCipherValidity *valid); @@ -274,9 +274,7 @@ efhd_class_init(GObjectClass *klass) { ((EMFormatClass *)klass)->find_handler = efhd_find_handler; ((EMFormatClass *)klass)->format_clone = efhd_format_clone; - ((EMFormatClass *)klass)->format_prefix = efhd_format_prefix; ((EMFormatClass *)klass)->format_error = efhd_format_error; - ((EMFormatClass *)klass)->format_message = efhd_format_message; ((EMFormatClass *)klass)->format_source = efhd_format_source; ((EMFormatClass *)klass)->format_attachment = efhd_format_attachment; ((EMFormatClass *)klass)->format_secure = efhd_format_secure; @@ -908,6 +906,7 @@ efhd_format_secure(EMFormat *emf, CamelStream *stream, CamelMimePart *part, Came /* ********************************************************************** */ static EMFormatHandler type_builtin_table[] = { + { "x-evolution/message/prefix", (EMFormatFunc)efhd_message_prefix }, }; static void @@ -970,7 +969,7 @@ efhd_write_image(EMFormat *emf, CamelStream *stream, EMFormatPURI *puri) camel_stream_close(stream); } -static void efhd_format_prefix(EMFormat *emf, CamelStream *stream) +static void efhd_message_prefix(EMFormat *emf, CamelStream *stream, CamelMimePart *part, EMFormatHandler *info) { const char *flag, *comp, *due; time_t date; @@ -1035,11 +1034,6 @@ static void efhd_format_error(EMFormat *emf, CamelStream *stream, const char *tx ((EMFormatClass *)efhd_parent)->format_error(emf, stream, txt); } -static void efhd_format_message(EMFormat *emf, CamelStream *stream, CamelMedium *part) -{ - ((EMFormatClass *)efhd_parent)->format_message(emf, stream, part); -} - static void efhd_format_source(EMFormat *emf, CamelStream *stream, CamelMimePart *part) { ((EMFormatClass *)efhd_parent)->format_source(emf, stream, part); -- cgit v1.2.3