Mercurial > pidgin
changeset 1140:249b040f6a83
[gaim-migrate @ 1150]
Pounce stuff is working now.
It still doesnt use the "per connection" info. Im just playing with the UI right now.
committer: Tailor Script <tailor@pidgin.im>
author | Rob Flynn <gaim@robflynn.com> |
---|---|
date | Mon, 27 Nov 2000 01:00:09 +0000 |
parents | ce935e673907 |
children | 8f4ce8b74901 |
files | src/dialogs.c src/server.c |
diffstat | 2 files changed, 28 insertions(+), 8 deletions(-) [+] |
line wrap: on
line diff
--- a/src/dialogs.c Sun Nov 26 11:46:49 2000 +0000 +++ b/src/dialogs.c Mon Nov 27 01:00:09 2000 +0000 @@ -1090,15 +1090,15 @@ struct aim_user *a; hbox = gtk_hbox_new(FALSE, 5); - gtk_box_pack_start(GTK_BOX(box), hbox, FALSE, FALSE, 5); + gtk_box_pack_start(GTK_BOX(box), hbox, FALSE, FALSE, 0); gtk_widget_show(hbox); label = gtk_label_new(_("Pounce buddy as:")); - gtk_box_pack_start(GTK_BOX(hbox), label, FALSE, FALSE, 5); + gtk_box_pack_start(GTK_BOX(hbox), label, FALSE, FALSE, 0); gtk_widget_show(label); optmenu = gtk_option_menu_new(); - gtk_box_pack_start(GTK_BOX(hbox), optmenu, FALSE, FALSE, 5); + gtk_box_pack_start(GTK_BOX(hbox), optmenu, FALSE, FALSE, 0); gtk_widget_show(optmenu); menu = gtk_menu_new(); @@ -1125,6 +1125,7 @@ GtkWidget *label; GtkWidget *bbox; GtkWidget *vbox; + GtkWidget *hbox; GtkWidget *button; struct addbp *b = g_new0(struct addbp, 1); @@ -1154,27 +1155,39 @@ /* Pounce as menu */ pounce_user_menu(b, vbox); - /* Put the buttons in the box */ + + hbox = gtk_hbox_new(FALSE, 5); + label = gtk_label_new(_("Buddy To Pounce:")); gtk_widget_show(label); - gtk_box_pack_start(GTK_BOX(vbox), label, FALSE, FALSE, 0); - gtk_box_pack_start(GTK_BOX(vbox), b->nameentry, FALSE, FALSE, 0); - + gtk_widget_show(hbox); + gtk_box_pack_start(GTK_BOX(hbox), label, FALSE, FALSE, 0); + gtk_box_pack_start(GTK_BOX(hbox), b->nameentry, FALSE, FALSE, 0); + gtk_box_pack_start(GTK_BOX(vbox), hbox, TRUE, TRUE, 0); + + + label = gtk_label_new(_("Events:")); + /* Set up the different options */ b->p_signon = gtk_check_button_new_with_label(_("Sign On")); b->p_unaway = gtk_check_button_new_with_label(_("Return from away")); b->p_unidle = gtk_check_button_new_with_label(_("Return from idle")); /* Show them */ + gtk_widget_show(label); gtk_widget_show(b->p_signon); gtk_widget_show(b->p_unaway); gtk_widget_show(b->p_unidle); /* And pack'em */ + gtk_box_pack_start(GTK_BOX(vbox), label, FALSE, FALSE, 0); gtk_box_pack_start(GTK_BOX(vbox), b->p_signon, FALSE, FALSE, 0); gtk_box_pack_start(GTK_BOX(vbox), b->p_unaway, FALSE, FALSE, 0); gtk_box_pack_start(GTK_BOX(vbox), b->p_unidle, FALSE, FALSE, 0); + + label = gtk_label_new(_("Actions:")); + /* And now the other stuff */ b->openwindow = gtk_check_button_new_with_label(_("Open IM window on pounce")); gtk_toggle_button_set_state(GTK_TOGGLE_BUTTON(b->openwindow), FALSE); @@ -1182,8 +1195,11 @@ b->sendim = gtk_check_button_new_with_label(_("Send IM on pounce")); gtk_toggle_button_set_state(GTK_TOGGLE_BUTTON(b->sendim), TRUE); + gtk_widget_show(label); gtk_widget_show(b->openwindow); gtk_widget_show(b->sendim); + + gtk_box_pack_start(GTK_BOX(vbox), label, TRUE, TRUE, 0); gtk_box_pack_start(GTK_BOX(vbox), b->openwindow, FALSE, FALSE, 0); gtk_box_pack_start(GTK_BOX(vbox), b->sendim, FALSE, FALSE, 0);
--- a/src/server.c Sun Nov 26 11:46:49 2000 +0000 +++ b/src/server.c Mon Nov 27 01:00:09 2000 +0000 @@ -451,12 +451,16 @@ } if (!b->idle && idle) plugin_event(event_buddy_idle, gc, b->name, 0, 0); - if (b->idle && !idle) plugin_event(event_buddy_unidle, gc, b->name, 0, 0); + if (b->idle && !idle) { + do_pounce(b->name); + plugin_event(event_buddy_unidle, gc, b->name, 0, 0); + } b->idle = idle; b->evil = evil; if ((b->uc & UC_UNAVAILABLE) && !(type & UC_UNAVAILABLE)) { + do_pounce(b->name); plugin_event(event_buddy_back, gc, b->name, 0, 0); } else if (!(b->uc & UC_UNAVAILABLE) && (type & UC_UNAVAILABLE)) { plugin_event(event_buddy_away, gc, b->name, 0, 0);