aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--mail/ChangeLog5
-rw-r--r--mail/mail-format.c16
2 files changed, 13 insertions, 8 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog
index 0d1f296a19..87901893bb 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -1,3 +1,8 @@
+2001-03-26 Radek Doulik <rodo@ximian.com>
+
+ * mail-format.c (write_address): clear name and email data after
+ each address
+
2001-03-25 Dan Winship <danw@ximian.com>
* component-factory.c (unref_standard_folders): Fix a bug in this
diff --git a/mail/mail-format.c b/mail/mail-format.c
index 83c15ece17..4957d01c27 100644
--- a/mail/mail-format.c
+++ b/mail/mail-format.c
@@ -627,7 +627,7 @@ static void
write_address(MailDisplay *md, const CamelInternetAddress *addr, const char *field_name, int flags)
{
const char *name, *email;
- gboolean name_set = FALSE, mail_set = FALSE;
+ gboolean name_set, mail_set;
gint i;
if (addr == NULL || !camel_internet_address_get (addr, 0, NULL, NULL))
@@ -644,6 +644,7 @@ write_address(MailDisplay *md, const CamelInternetAddress *addr, const char *fie
mail_html_write (md->html, md->stream, i ? ",<B> </B> " : "<td>");
mail_html_write (md->html, md->stream, " ");
+ name_set = mail_set = FALSE;
if (name && *name) {
mail_html_write (md->html, md->stream,
"<!--+GtkHTML:<DATA class=\"Text\" key=\"name\" value=\"%s\">-->",
@@ -665,17 +666,16 @@ write_address(MailDisplay *md, const CamelInternetAddress *addr, const char *fie
name && *name ? "&lt;" : "",
email,
name && *name ? "&gt;" : "");
+ if (name_set)
+ mail_html_write (md->html, md->stream,
+ "<!--+GtkHTML:<DATA class=\"Text\" clear=\"name\">-->");
+ if (mail_set)
+ mail_html_write (md->html, md->stream,
+ "<!--+GtkHTML:<DATA class=\"Text\" clear=\"email\">-->");
}
++i;
}
- if (name_set)
- mail_html_write (md->html, md->stream,
- "<!--+GtkHTML:<DATA class=\"Text\" clear=\"name\">-->");
- if (mail_set)
- mail_html_write (md->html, md->stream,
- "<!--+GtkHTML:<DATA class=\"Text\" clear=\"email\">-->");
-
mail_html_write (md->html, md->stream, "</td></tr>"); /* Finish up the table row */
}