diff options
Diffstat (limited to 'camel')
-rw-r--r-- | camel/camel-formatter.c | 76 |
1 files changed, 0 insertions, 76 deletions
diff --git a/camel/camel-formatter.c b/camel/camel-formatter.c index 08e911f03c..f2e35aac2f 100644 --- a/camel/camel-formatter.c +++ b/camel/camel-formatter.c @@ -661,80 +661,4 @@ _finalize (GtkObject* object) } -<<<<<<< camel-formatter.c -======= -/* GARBAGE GARBAGE GARBAGE GARBAGE GARBAGE GARBAGE */ -/* GARBAGE GARBAGE GARBAGE GARBAGE GARBAGE GARBAGE */ -/* GARBAGE GARBAGE GARBAGE GARBAGE GARBAGE GARBAGE */ -/* Converts the contents of a CamelMimePart into HTML */ -static void -mime_part_to_html (CamelFormatter* formatter, CamelMimePart* part, - CamelStream* stream) -{ - /* Get the mime-type of the mime message */ - gchar* mime_type_whole = /* ex. "text/plain" */ - MIME_TYPE_WHOLE (part); - - /* get the contents of the mime message */ - CamelDataWrapper* message_contents = - camel_medium_get_content_object (CAMEL_MEDIUM (part)); - - /* if we're dealing with a multipart/related message... */ - if (strcase_equal (MIME_TYPE_WHOLE (part), "multipart/related")) { - - CamelMultipart *multipart = CAMEL_MULTIPART ( - message_contents); - - int i, max_multiparts; - - /* find out out many parts are in it...*/ - max_multiparts = camel_multipart_get_number (multipart); - - /* ...and write each one, as html, into the stream. */ - for (i = 0; i < max_multiparts; i++) { - CamelMimeBodyPart* body_part = - camel_multipart_get_part (multipart, i); - - /* TODO: insert html delimiters, probably - * <hr>'s, before and after the following - * call*/ - mime_part_to_html ( - formatter, CAMEL_MIME_PART (body_part), - stream); - } - } - - /* okay, it's not multipart-related, so we have only one 'thing' - * to convert to html */ - else { - CamelMimePart* mime_part = NULL; - - /* if it's a multipart/alternate, track down one we can - * convert to html (if any) */ - if (strcase_equal (mime_type_whole, "multipart/alternate")) { - mime_part = - find_preferred_displayable_body_part_in_multipart_alternative ( - CAMEL_MULTIPART(message_contents)); - } - - else if (strcase_equal (mime_type_whole, "text/plain") || - strcase_equal (mime_type_whole, "text/html")) { - - mime_part = CAMEL_MIME_PART (message_contents); - } - - if (message_contents) { - - } - else { - gchar *error_string = g_strdup_printf ( - "Sorry, but I don't know how to display items of type %s\n", - mime_type_whole); - - camel_stream_write_string (stream, error_string); - g_free (error_string); - } - } -} ->>>>>>> 1.6 |