# HG changeset patch # User Sean Egan # Date 1020103647 0 # Node ID 3d2d57dba56b1f5aaaa1ba4f89a437d247e6335d # Parent db7b4fa85776e6fcd5ac97f4842928a44c8cd75b [gaim-migrate @ 3209] A new preference! Raise your buddy list when someone signs on or off committer: Tailor Script diff -r db7b4fa85776 -r 3d2d57dba56b ChangeLog --- a/ChangeLog Mon Apr 29 13:15:41 2002 +0000 +++ b/ChangeLog Mon Apr 29 18:07:27 2002 +0000 @@ -4,6 +4,7 @@ * Bulgarian translation added (Thanks, Igel Itzo) * Taiwanese translation added (Thanks, Paladin Liu) * Better applet transparency + * Option to raise buddy list on signons/signoffs version 0.57 (04/25/2002): * New authorization method for Yahoo! diff -r db7b4fa85776 -r 3d2d57dba56b src/buddy.c --- a/src/buddy.c Mon Apr 29 13:15:41 2002 +0000 +++ b/src/buddy.c Mon Apr 29 18:07:27 2002 +0000 @@ -1987,7 +1987,7 @@ } void hide_buddy_list() { - #ifdef USE_APPLET +#ifdef USE_APPLET applet_destroy_buddy(NULL, NULL, NULL); #else XIconifyWindow(GDK_DISPLAY(), @@ -1996,6 +1996,16 @@ #endif } +void unhide_buddy_list() { +#ifdef USE_APPLET + if (!applet_buddy_show) { + applet_buddy_show = TRUE; + createOnlinePopup(); + } +#endif /* USE_APPLET */ + gdk_window_show(blist->window); +} + static gint log_timeout(struct buddy_show *b) { /* this part is really just a bad hack because of a bug I can't find */ @@ -2279,6 +2289,8 @@ if (b->present == 1) { if (bs->sound != 2) play_sound(SND_BUDDY_ARRIVE); + if (blist_options & OPT_BLIST_POPUP) + unhide_buddy_list(); pm = gdk_pixmap_create_from_xpm_d(blist->window, &bm, NULL, (char **)login_icon_xpm); gtk_widget_hide(bs->pix); @@ -2342,7 +2354,8 @@ off */ if (bs->sound != 1) play_sound(SND_BUDDY_LEAVE); - + if (blist_options & OPT_BLIST_POPUP) + unhide_buddy_list(); bs->connlist = g_slist_remove(bs->connlist, gc); update_num_group(gs); if (bs->log_timer > 0) diff -r db7b4fa85776 -r 3d2d57dba56b src/gaim.h --- a/src/gaim.h Mon Apr 29 13:15:41 2002 +0000 +++ b/src/gaim.h Mon Apr 29 18:07:27 2002 +0000 @@ -211,6 +211,7 @@ #define OPT_BLIST_SHOW_WARN 0x00000200 #define OPT_BLIST_GREY_IDLERS 0x00000400 #define OPT_BLIST_BOTTOM_TAB 0X00000800 +#define OPT_BLIST_POPUP 0x00001000 extern guint convo_options; #define OPT_CONVO_ENTER_SENDS 0x00000001 diff -r db7b4fa85776 -r 3d2d57dba56b src/prefs.c --- a/src/prefs.c Mon Apr 29 13:15:41 2002 +0000 +++ b/src/prefs.c Mon Apr 29 18:07:27 2002 +0000 @@ -596,6 +596,7 @@ if (blist_options & OPT_BLIST_NO_BUTTONS) gtk_widget_set_sensitive(button2, FALSE); gtk_signal_connect(GTK_OBJECT(button), "clicked", GTK_SIGNAL_FUNC(toggle_sensitive), button2); + gaim_button(_("Raise Buddy List on Signons and Signoffs"), &blist_options, OPT_BLIST_POPUP, vbox); frame = gtk_frame_new(_("Group Displays")); gtk_box_pack_start(GTK_BOX(box), frame, FALSE, FALSE, 5);