aboutsummaryrefslogtreecommitdiffstats
path: root/libempathy-gtk
diff options
context:
space:
mode:
Diffstat (limited to 'libempathy-gtk')
-rw-r--r--libempathy-gtk/empathy-contact-widget.c8
-rw-r--r--libempathy-gtk/empathy-contactinfo-utils.c8
-rw-r--r--libempathy-gtk/empathy-contactinfo-utils.h3
-rw-r--r--libempathy-gtk/empathy-individual-widget.c2
4 files changed, 15 insertions, 6 deletions
diff --git a/libempathy-gtk/empathy-contact-widget.c b/libempathy-gtk/empathy-contact-widget.c
index 1b04fb751..edeec31f4 100644
--- a/libempathy-gtk/empathy-contact-widget.c
+++ b/libempathy-gtk/empathy-contact-widget.c
@@ -409,10 +409,14 @@ contact_widget_details_update_edit (EmpathyContactWidget *information)
/* Add Title */
title = empathy_contact_info_field_label (field->field_name,
- field->parameters);
+ field->parameters,
+ (spec->flags & TP_CONTACT_INFO_FIELD_FLAG_PARAMETERS_EXACT));
w = gtk_label_new (title);
g_free (title);
+ /* TODO: if TP_CONTACT_INFO_FIELD_FLAG_PARAMETERS_EXACT is not set we
+ * should allow user to tag the vCard fields (bgo#672034) */
+
gtk_grid_attach (GTK_GRID (information->grid_details),
w, 0, n_rows, 1, 1);
@@ -529,7 +533,7 @@ contact_widget_details_update_show (EmpathyContactWidget *information)
/* Add Title */
title = empathy_contact_info_field_label (field->field_name,
- field->parameters);
+ field->parameters, TRUE);
title_widget = gtk_label_new (title);
g_free (title);
diff --git a/libempathy-gtk/empathy-contactinfo-utils.c b/libempathy-gtk/empathy-contactinfo-utils.c
index b995297b0..270566721 100644
--- a/libempathy-gtk/empathy-contactinfo-utils.c
+++ b/libempathy-gtk/empathy-contactinfo-utils.c
@@ -213,15 +213,19 @@ build_parameters_string (GStrv parameters)
char *
empathy_contact_info_field_label (const char *field_name,
- GStrv parameters)
+ GStrv parameters,
+ gboolean show_parameters)
{
char *ret;
const char *title;
- char *join = build_parameters_string (parameters);
+ char *join = NULL;
if (!empathy_contact_info_lookup_field (field_name, &title, NULL))
return NULL;
+ if (show_parameters)
+ join = build_parameters_string (parameters);
+
if (join != NULL)
ret = g_strdup_printf ("%s (%s):", title, join);
else
diff --git a/libempathy-gtk/empathy-contactinfo-utils.h b/libempathy-gtk/empathy-contactinfo-utils.h
index a49e807aa..b91f419c8 100644
--- a/libempathy-gtk/empathy-contactinfo-utils.h
+++ b/libempathy-gtk/empathy-contactinfo-utils.h
@@ -34,7 +34,8 @@ const char **empathy_contact_info_get_field_names (guint *nnames);
gboolean empathy_contact_info_lookup_field (const gchar *field_name,
const gchar **title, EmpathyContactInfoFormatFunc *linkify);
char *empathy_contact_info_field_label (const char *field_name,
- GStrv parameters);
+ GStrv parameters,
+ gboolean show_parameters);
gint empathy_contact_info_field_cmp (TpContactInfoField *field1,
TpContactInfoField *field2);
diff --git a/libempathy-gtk/empathy-individual-widget.c b/libempathy-gtk/empathy-individual-widget.c
index 3cbd1d5e3..e103eff6d 100644
--- a/libempathy-gtk/empathy-individual-widget.c
+++ b/libempathy-gtk/empathy-individual-widget.c
@@ -267,7 +267,7 @@ details_update_show (EmpathyIndividualWidget *self,
/* Add Title */
title = empathy_contact_info_field_label (field->field_name,
- field->parameters);
+ field->parameters, TRUE);
title_widget = gtk_label_new (title);
/* Add Value */