diff options
author | Ted Gould <ted@gould.cx> | 2010-08-24 15:06:41 -0500 |
---|---|---|
committer | Ted Gould <ted@gould.cx> | 2010-08-24 15:06:41 -0500 |
commit | 422423618105395db6ca9316ea78d58d92d136b4 (patch) | |
tree | b1093e12b2a89b6e6a2fabb04f540adc73d40c4d | |
parent | de84a7600cbe17e38f7fcca07095b105e21e1dea (diff) | |
download | ayatana-indicator-messages-422423618105395db6ca9316ea78d58d92d136b4.tar.gz ayatana-indicator-messages-422423618105395db6ca9316ea78d58d92d136b4.tar.bz2 ayatana-indicator-messages-422423618105395db6ca9316ea78d58d92d136b4.zip |
Only show the avatar if it is sent
-rw-r--r-- | src/indicator-messages.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/indicator-messages.c b/src/indicator-messages.c index dcb57dc..9039af7 100644 --- a/src/indicator-messages.c +++ b/src/indicator-messages.c @@ -489,6 +489,10 @@ indicator_prop_change_cb (DbusmenuMenuitem * mi, gchar * prop, GValue * value, i if (resized_pixbuf != pixbuf) { g_object_unref(resized_pixbuf); } + + gtk_widget_show(mi_data->icon); + } else { + gtk_widget_hide(mi_data->icon); } } @@ -550,7 +554,10 @@ new_indicator_item (DbusmenuMenuitem * newitem, DbusmenuMenuitem * parent, Dbusm } gtk_misc_set_alignment(GTK_MISC(mi_data->icon), 0.0, 0.5); gtk_box_pack_start(GTK_BOX(hbox), mi_data->icon, FALSE, FALSE, padding); - gtk_widget_show(mi_data->icon); + + if (pixbuf != NULL) { + gtk_widget_show(mi_data->icon); + } /* Label, probably a username, chat room or mailbox name */ mi_data->label = gtk_label_new(dbusmenu_menuitem_property_get(newitem, INDICATOR_MENUITEM_PROP_LABEL)); |