changeset 2625:d8d2df2bdf01

[gaim-migrate @ 2638] runny nose and runny yolk, even if you have a cold still you can cough on my again, i still haven't had my full fill committer: Tailor Script <tailor@pidgin.im>
author Eric Warmenhoven <eric@warmenhoven.org>
date Sat, 27 Oct 2001 00:12:14 +0000
parents 4d5c2c913750
children 93f9bbd62630
files src/buddy_chat.c src/conversation.c src/ui.h
diffstat 3 files changed, 18 insertions(+), 8 deletions(-) [+]
line wrap: on
line diff
--- a/src/buddy_chat.c	Fri Oct 26 23:49:50 2001 +0000
+++ b/src/buddy_chat.c	Sat Oct 27 00:12:14 2001 +0000
@@ -1074,7 +1074,7 @@
 	style->font = gdk_font_ref(label->style->font);
 	gtk_widget_set_style(label, style);
 	gtk_style_unref(style);
-	b->unseen = FALSE;
+	b->unseen = 0;
 }
 
 void show_new_buddy_chat(struct conversation *b)
--- a/src/conversation.c	Fri Oct 26 23:49:50 2001 +0000
+++ b/src/conversation.c	Sat Oct 27 00:12:14 2001 +0000
@@ -1597,17 +1597,27 @@
 											(notebook),
 											g_list_index(ws,
 												     c)));
-		GtkStyle *style = gtk_style_new();
+		GtkStyle *style;
+		if ((c->unseen == 2) || ((c->unseen == 1) && !(flags & WFLAG_NICK)))
+			return;
+		style = gtk_style_new();
 		if (!GTK_WIDGET_REALIZED(label))
 			gtk_widget_realize(label);
 		gdk_font_unref(style->font);
 		style->font = gdk_font_ref(label->style->font);
-		style->fg[0].red = 0xcccc;
-		style->fg[0].green = 0x0000;
-		style->fg[0].blue = 0x0000;
+		if (flags & WFLAG_NICK) {
+			style->fg[0].red = 0x0000;
+			style->fg[0].green = 0x0000;
+			style->fg[0].blue = 0xcccc;
+			c->unseen = 2;
+		} else {
+			style->fg[0].red = 0xcccc;
+			style->fg[0].green = 0x0000;
+			style->fg[0].blue = 0x0000;
+			c->unseen = 1;
+		}
 		gtk_widget_set_style(label, style);
 		gtk_style_unref(style);
-		c->unseen = TRUE;
 	}
 }
 
@@ -2102,7 +2112,7 @@
 	style->font = gdk_font_ref(label->style->font);
 	gtk_widget_set_style(label, style);
 	gtk_style_unref(style);
-	c->unseen = FALSE;
+	c->unseen = 0;
 }
 
 
--- a/src/ui.h	Fri Oct 26 23:49:50 2001 +0000
+++ b/src/ui.h	Sat Oct 27 00:12:14 2001 +0000
@@ -136,7 +136,7 @@
 	GtkWidget *sep2;
 	GtkWidget *menu;
 	GtkWidget *check;
-	gboolean unseen;
+	gint unseen;
 
 	/* stuff used just for chat */
         GList *in_room;