From 87842463373ddfbed87fdf27a617f1b35fb35d41 Mon Sep 17 00:00:00 2001 From: Sjoerd Simons Date: Tue, 22 Mar 2011 19:57:25 +0000 Subject: Cope with gtk_icon_theme_lookup_icon returning NULL --- libempathy-gtk/empathy-ui-utils.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/libempathy-gtk/empathy-ui-utils.c b/libempathy-gtk/empathy-ui-utils.c index d5f63c9e0..8822ccdf6 100644 --- a/libempathy-gtk/empathy-ui-utils.c +++ b/libempathy-gtk/empathy-ui-utils.c @@ -947,6 +947,9 @@ empathy_filename_from_icon_name (const gchar *icon_name, } icon_info = gtk_icon_theme_lookup_icon (icon_theme, icon_name, size, 0); + if (icon_info == NULL) + return NULL; + ret = g_strdup (gtk_icon_info_get_filename (icon_info)); gtk_icon_info_free (icon_info); -- cgit v1.2.3 From c6e11eb4767148a799ab565de508886ffa7fa86f Mon Sep 17 00:00:00 2001 From: Emilio Pozuelo Monfort Date: Fri, 15 Apr 2011 18:12:59 +0100 Subject: Display an accurate error when not enough credit --- libempathy-gtk/empathy-call-utils.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/libempathy-gtk/empathy-call-utils.c b/libempathy-gtk/empathy-call-utils.c index eb01fe25b..0926230ec 100644 --- a/libempathy-gtk/empathy-call-utils.c +++ b/libempathy-gtk/empathy-call-utils.c @@ -55,6 +55,8 @@ get_error_display_message (GError *error) return _("The specified contact is not valid"); case TP_ERROR_EMERGENCY_CALLS_NOT_SUPPORTED: return _("Emergency calls are not supported on this protocol"); + case TP_ERROR_INSUFFICIENT_BALANCE: + return _("You don't have enough credit in order to place this call"); } return _("There was an error starting the call"); -- cgit v1.2.3 From 2f9a520747ceacc89e5d6d923ed0cda8da22b95c Mon Sep 17 00:00:00 2001 From: Emilio Pozuelo Monfort Date: Fri, 3 Jun 2011 11:30:07 +0100 Subject: CallWindow: correctly detect outgoing calls --- src/empathy-call-window.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/empathy-call-window.c b/src/empathy-call-window.c index ccec9f628..05f63e2f6 100644 --- a/src/empathy-call-window.c +++ b/src/empathy-call-window.c @@ -1993,13 +1993,14 @@ empathy_call_window_constructed (GObject *object) EmpathyCallWindow *self = EMPATHY_CALL_WINDOW (object); EmpathyCallWindowPriv *priv = GET_PRIV (self); TpyCallChannel *call; + TpyCallState state; g_assert (priv->handler != NULL); g_object_get (priv->handler, "call-channel", &call, NULL); - priv->outgoing = (call == NULL); - if (call != NULL) - g_object_unref (call); + state = tpy_call_channel_get_state (call, NULL, NULL); + priv->outgoing = (state == TPY_CALL_STATE_PENDING_INITIATOR); + tp_clear_object (&call); g_object_get (priv->handler, "target-contact", &priv->contact, NULL); g_assert (priv->contact != NULL); -- cgit v1.2.3