From 4c20fe02c4bf78e56caf5393598fdb71b4ac772e Mon Sep 17 00:00:00 2001 From: Jeffrey Stedfast Date: Tue, 4 Jun 2002 23:58:22 +0000 Subject: The following changes take a great leap toward fixing bug #1042. 2002-06-04 Jeffrey Stedfast The following changes take a great leap toward fixing bug #1042. * mail-display.c (mail_display_push_content_location): New function to push a Content-Location value onto the MailDisplay. (mail_display_get_content_location): Gets the current Content-Location CamelURL value. (mail_display_pop_content_location): Pop the Content-Location off the stack. * mail-format.c (get_location): Do URL merging if the Content-Location isn't a full URL. If the Content-Location doesn't exist, pretend the URL is actually the Content-Location URL of our parent multipart (assuming it exists). If that doesn't exist, then yes - return NULL. (handle_multipart_related): Push the Content-Location header value of the multipart/related so that we can do URL merging in get_location() as we process each of the subparts. When we're done, pop it back off the stack. svn path=/trunk/; revision=17113 --- mail/mail-display.h | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) (limited to 'mail/mail-display.h') diff --git a/mail/mail-display.h b/mail/mail-display.h index 0fcd98ab00..80d17d78c3 100644 --- a/mail/mail-display.h +++ b/mail/mail-display.h @@ -31,7 +31,7 @@ struct _MailDisplay { gint redisplay_counter; gpointer last_active; guint idle_id; - + char *charset; char *selection; @@ -40,6 +40,11 @@ struct _MailDisplay { CamelMimeMessage *current_message; GData **data; + /* stack of Content-Location URLs used for combining with a + relative URL Content-Location on a leaf part in order to + construct the full URL */ + struct _location_url_stack *urls; + GHashTable *related; /* related parts not displayed yet */ /* Sigh. This shouldn't be needed. I haven't figured out why it is @@ -47,7 +52,7 @@ struct _MailDisplay { GtkWidget *invisible; MailConfigDisplayStyle display_style; - + guint printing : 1; }; @@ -100,4 +105,8 @@ char *mail_display_add_url (MailDisplay *md, const char *kind, char *url, gpoint const char *mail_display_get_url_for_icon (MailDisplay *md, const char *icon_name); +void mail_display_push_content_location (MailDisplay *md, const char *location); +CamelURL *mail_display_get_content_location (MailDisplay *md); +void mail_display_pop_content_location (MailDisplay *md); + #endif /* _MAIL_DISPLAY_H_ */ -- cgit v1.2.3