aboutsummaryrefslogtreecommitdiffstats
path: root/addressbook/gui
diff options
context:
space:
mode:
authorMilan Crha <mcrha@redhat.com>2013-11-21 01:04:10 +0800
committerMilan Crha <mcrha@redhat.com>2013-11-21 01:04:10 +0800
commitc980a3dc64247126a8ce1a0e9bf4bc932b7304f6 (patch)
treed4e446f7757d8dd2b489a6ade6442a380c0e302d /addressbook/gui
parentf416f05344176ef363f8b4e3b9ac8aca0dde9a89 (diff)
downloadgsoc2013-evolution-c980a3dc64247126a8ce1a0e9bf4bc932b7304f6.tar
gsoc2013-evolution-c980a3dc64247126a8ce1a0e9bf4bc932b7304f6.tar.gz
gsoc2013-evolution-c980a3dc64247126a8ce1a0e9bf4bc932b7304f6.tar.bz2
gsoc2013-evolution-c980a3dc64247126a8ce1a0e9bf4bc932b7304f6.tar.lz
gsoc2013-evolution-c980a3dc64247126a8ce1a0e9bf4bc932b7304f6.tar.xz
gsoc2013-evolution-c980a3dc64247126a8ce1a0e9bf4bc932b7304f6.tar.zst
gsoc2013-evolution-c980a3dc64247126a8ce1a0e9bf4bc932b7304f6.zip
Bug #711669 - "Other address" is not displayed in preview
Diffstat (limited to 'addressbook/gui')
-rw-r--r--addressbook/gui/widgets/eab-contact-formatter.c24
1 files changed, 24 insertions, 0 deletions
diff --git a/addressbook/gui/widgets/eab-contact-formatter.c b/addressbook/gui/widgets/eab-contact-formatter.c
index 8dbfddf35b..0601291ed4 100644
--- a/addressbook/gui/widgets/eab-contact-formatter.c
+++ b/addressbook/gui/widgets/eab-contact-formatter.c
@@ -700,6 +700,29 @@ render_personal_column (EABContactFormatter *formatter,
}
static void
+render_other_column (EABContactFormatter *formatter,
+ EContact *contact,
+ GString *buffer)
+{
+ GString *accum = g_string_new ("");
+
+ accum_address (accum, contact, _("Address"), E_CONTACT_ADDRESS_OTHER, E_CONTACT_ADDRESS_LABEL_OTHER);
+ if (formatter->priv->render_maps)
+ accum_address_map (accum, contact, E_CONTACT_ADDRESS_OTHER);
+
+ if (accum->len > 0) {
+ g_string_append_printf (
+ buffer,
+ "<div class=\"column\" id=\"contact-other\">"
+ "<h3>%s</h3>"
+ "<table border=\"0\" cellspacing=\"5\">%s</table>"
+ "</div>", _("Other"), accum->str);
+ }
+
+ g_string_free (accum, TRUE);
+}
+
+static void
render_footer (EABContactFormatter *formatter,
EContact *contact,
GString *buffer)
@@ -736,6 +759,7 @@ render_contact (EABContactFormatter *formatter,
render_contact_column (formatter, contact, buffer);
render_work_column (formatter, contact, buffer);
render_personal_column (formatter, contact, buffer);
+ render_other_column (formatter, contact, buffer);
g_string_append (buffer, "</div>");
render_footer (formatter, contact, buffer);