empathy r1685 - trunk/libempathy-gtk
- From: xclaesse svn gnome org
- To: svn-commits-list gnome org
- Subject: empathy r1685 - trunk/libempathy-gtk
- Date: Tue, 11 Nov 2008 15:26:36 +0000 (UTC)
Author: xclaesse
Date: Tue Nov 11 15:26:36 2008
New Revision: 1685
URL: http://svn.gnome.org/viewvc/empathy?rev=1685&view=rev
Log:
Check the contact factory is still ready when avatar picker is OKed.
Modified:
trunk/libempathy-gtk/empathy-avatar-chooser.c
Modified: trunk/libempathy-gtk/empathy-avatar-chooser.c
==============================================================================
--- trunk/libempathy-gtk/empathy-avatar-chooser.c (original)
+++ trunk/libempathy-gtk/empathy-avatar-chooser.c Tue Nov 11 15:26:36 2008
@@ -756,6 +756,18 @@
gint response,
EmpathyAvatarChooser *chooser)
{
+ EmpathyAvatarChooserPriv *priv = GET_PRIV (chooser);
+
+ if (response == GTK_RESPONSE_CANCEL) {
+ goto out;
+ }
+
+ /* Check if we went non-ready since displaying the dialog. */
+ if (!empathy_tp_contact_factory_is_ready (priv->tp_contact_factory)) {
+ DEBUG ("Can't set avatar when contact factory isn't ready.");
+ goto out;
+ }
+
if (response == GTK_RESPONSE_OK) {
gchar *filename;
gchar *path;
@@ -777,6 +789,7 @@
avatar_chooser_clear_image (chooser);
}
+out:
gtk_widget_destroy (widget);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]