diff options
-rw-r--r-- | src/empathy-call-window.c | 22 | ||||
-rw-r--r-- | src/empathy-call-window.ui | 48 |
2 files changed, 37 insertions, 33 deletions
diff --git a/src/empathy-call-window.c b/src/empathy-call-window.c index 564504f99..1301f96d1 100644 --- a/src/empathy-call-window.c +++ b/src/empathy-call-window.c @@ -161,6 +161,7 @@ struct _EmpathyCallWindowPriv GtkWidget *remote_user_avatar_widget; GtkWidget *remote_user_avatar_toolbar; GtkWidget *remote_user_name_toolbar; + GtkWidget *remote_user_status_toolbar; GtkWidget *status_label; GtkWidget *hangup_button; GtkWidget *audio_call_button; @@ -1564,6 +1565,7 @@ empathy_call_window_init (EmpathyCallWindow *self) "errors_vbox", &priv->errors_vbox, "pane", &priv->pane, "remote_user_name_toolbar", &priv->remote_user_name_toolbar, + "remote_user_status_toolbar", &priv->remote_user_status_toolbar, "remote_user_avatar_toolbar", &priv->remote_user_avatar_toolbar, "status_label", &priv->status_label, "audiocall", &priv->audio_call_button, @@ -1873,16 +1875,20 @@ set_remote_user_name (EmpathyCallWindow *self, { const gchar *alias = empathy_contact_get_alias (contact); const gchar *status = empathy_contact_get_status (contact); - gchar *label; - if (status != NULL) - label = g_strdup_printf ("%s\n<small>%s</small>", alias, status); - else - label = g_strdup (alias); + gtk_label_set_text (GTK_LABEL (self->priv->remote_user_name_toolbar), alias); + + if (status != NULL) { + gchar *markup; - gtk_label_set_markup (GTK_LABEL (self->priv->remote_user_name_toolbar), - label); - g_free (label); + markup = g_markup_printf_escaped ("<small>%s</small>", status); + gtk_label_set_markup (GTK_LABEL (self->priv->remote_user_status_toolbar), + markup); + g_free (markup); + } else { + gtk_label_set_markup (GTK_LABEL (self->priv->remote_user_status_toolbar), + ""); + } } static void diff --git a/src/empathy-call-window.ui b/src/empathy-call-window.ui index 2158b2b83..2caa242b8 100644 --- a/src/empathy-call-window.ui +++ b/src/empathy-call-window.ui @@ -164,27 +164,37 @@ <property name="draw">False</property> <property name="visible">True</property> </object> - <packing> - <property name="homogeneous">True</property> - </packing> </child> <child> + <object class="GtkToolItem" id="toolitem2"> <property name="visible">True</property> <child> - <object class="GtkLabel" id="remote_user_name_toolbar"> - <property name="visible">True</property> + <object class="GtkVBox" id="uservbox"> + <child> + <object class="GtkLabel" id="remote_user_name_toolbar"> + <property name="visible">True</property> + <property name="ellipsize">PANGO_ELLIPSIZE_END</property> + <property name="xalign">0</property> + </object> + <packing> + <property name="fill">False</property> + </packing> + </child> + <child> + <object class="GtkLabel" id="remote_user_status_toolbar"> + <property name="visible">True</property> + <property name="ellipsize">PANGO_ELLIPSIZE_END</property> + <property name="xalign">0</property> + </object> + <packing> + <property name="fill">False</property> + </packing> + </child> </object> </child> </object> - </child> - <child> - <object class="GtkToolItem" id="toolbar_space1"> - <property name="visible">True</property> - </object> - <packing> - <property name="expand">True</property> - </packing> + <packing> <property name="expand">True</property></packing> </child> <child> <object class="GtkToolButton" id="hangup"> @@ -193,9 +203,6 @@ <property name="icon_name">call-stop</property> <property name="tooltip_text" translatable="yes">Hang up current call</property> </object> - <packing> - <property name="homogeneous">False</property> - </packing> </child> <child> <object class="GtkToolButton" id="videocall"> @@ -203,9 +210,6 @@ <property name="icon_name">camera-web</property> <property name="tooltip_text" translatable="yes">Start a video call</property> </object> - <packing> - <property name="homogeneous">True</property> - </packing> </child> <child> <object class="GtkToolButton" id="audiocall"> @@ -213,9 +217,6 @@ <property name="icon_name">call-start</property> <property name="tooltip_text" translatable="yes">Start an audio call</property> </object> - <packing> - <property name="homogeneous">True</property> - </packing> </child> <child> <object class="GtkToggleToolButton" id="dialpad"> @@ -224,9 +225,6 @@ <property name="icon_name">input-dialpad</property> <property name="tooltip_text" translatable="yes">Display the dialpad</property> </object> - <packing> - <property name="homogeneous">True</property> - </packing> </child> </object> <packing> |