changeset 1857:9ea0b9531bc9

[gaim-migrate @ 1867] hi committer: Tailor Script <tailor@pidgin.im>
author Eric Warmenhoven <eric@warmenhoven.org>
date Fri, 18 May 2001 23:58:13 +0000
parents 8f06476b1296
children 487d98cdbe28
files src/buddy.c
diffstat 1 files changed, 12 insertions(+), 11 deletions(-) [+]
line wrap: on
line diff
--- a/src/buddy.c	Thu May 17 17:25:26 2001 +0000
+++ b/src/buddy.c	Fri May 18 23:58:13 2001 +0000
@@ -1699,7 +1699,7 @@
         
 	who = g_strdup(normalize(name));
 
-	while(bp) {
+	while (bp) {
 		b = (struct buddy_pounce *)bp->data;
 		bp = bp->next; /* increment the list here because rem_bp can make our handle bad */
 
@@ -1712,14 +1712,17 @@
 		if (u->gc == NULL) continue;
 		
                 if (!strcasecmp(who, normalize(b->name))) { /* find someone to pounce */
-			if (b->options & OPT_POUNCE_POPUP)
-			{
+			if (b->options & OPT_POUNCE_POPUP) {
 				c = find_conversation(name);
 				if (c == NULL)
+
+				c->gc = u->gc;
+				gtk_option_menu_set_history(GTK_OPTION_MENU(c->menu),
+						g_slist_index(connections, u->gc));
+				update_buttons_by_protocol(c);
 					c = new_conversation(name);
 			}
-			if (b->options & OPT_POUNCE_SEND_IM)
-			{
+			if (b->options & OPT_POUNCE_SEND_IM) {
                         	c = find_conversation(name);
                         	if (c == NULL)
                                 	c = new_conversation(name);
@@ -1732,8 +1735,7 @@
                         	write_to_conv(c, b->message, WFLAG_SEND, NULL, time((time_t)NULL));
                                 serv_send_im(u->gc, name, b->message, 0);
 			}
-			if (b->options & OPT_POUNCE_COMMAND)
-			{
+			if (b->options & OPT_POUNCE_COMMAND) {
 				int pid = fork();
 
 				if (pid == 0) {
@@ -1748,12 +1750,11 @@
 					gtk_timeout_add(100, (GtkFunction)clean_pid, NULL);
 				}
 			}
-			if (b->options & OPT_POUNCE_SOUND)
-			{
+			if (b->options & OPT_POUNCE_SOUND) {
 				if(strlen(b->sound))
-					play_file(b->sound); //play given sound
+					play_file(b->sound);
 				else
-					play_sound(POUNCE_DEFAULT); //play default sound
+					play_sound(POUNCE_DEFAULT);
 			}
                         
 			if (!(b->options & OPT_POUNCE_SAVE))