changeset 20061:e80e40e313ed

Gray offline buddy icons when setting them as window icons. Fixes #302
author Sean Egan <seanegan@gmail.com>
date Sat, 15 Sep 2007 20:53:42 +0000
parents ed5254916b75
children 0c84170f5778
files pidgin/gtkconv.c
diffstat 1 files changed, 5 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/pidgin/gtkconv.c	Sat Sep 15 20:36:54 2007 +0000
+++ b/pidgin/gtkconv.c	Sat Sep 15 20:53:42 2007 +0000
@@ -6414,8 +6414,13 @@
 		if ((purple_conversation_get_type(conv) == PURPLE_CONV_TYPE_IM) &&
 				(gtkconv->u.im->anim))
 		{
+			PurpleBuddy *buddy = purple_find_buddy(conv->account, conv->name);
 			window_icon =
 				gdk_pixbuf_animation_get_static_image(gtkconv->u.im->anim);
+		
+			if (buddy &&  !PURPLE_BUDDY_IS_ONLINE(buddy))
+				gdk_pixbuf_saturate_and_pixelate(window_icon, window_icon, 0.0, FALSE);
+			
 			g_object_ref(window_icon);
 			l = g_list_append(l, window_icon);
 		} else {