# HG changeset patch # User Eric Warmenhoven # Date 978653863 0 # Node ID aedeb1218a0a041e23780069a98d72c1a246eed1 # Parent 569835fcabc3f0a74560e8bf0d1d8af12bf385f9 [gaim-migrate @ 1388] libfaim has a bad cap for Games, update the TODO for Jabber stuff, and make autorecon.c work better, I hope committer: Tailor Script diff -r 569835fcabc3 -r aedeb1218a0a TODO --- a/TODO Thu Jan 04 23:29:52 2001 +0000 +++ b/TODO Fri Jan 05 00:17:43 2001 +0000 @@ -3,16 +3,15 @@ Make Yahoo plugin let you have two identities in the same connection (different from multiple connections) Figure out some way of not displaying a million new mail messages - Allow messages through server for ICQ File transfer for IRC? Maybe later? - Chat for Yahoo/ICQ + Chat for Yahoo/ICQ/Jabber File transfer for Yahoo/ICQ/Oscar/Napster Working file transfer for TOC Other RVOUS actions for TOC/Oscar - Get Jabber working + Jabber Transports Fix MSN signon process Make it so you can register new accounts via gaim - Napster user registration + Jabber/ICQ/Napster user registration Syd is cool and gave all of these ideas: Have multiple tickers in the same window, one for buddies diff -r 569835fcabc3 -r aedeb1218a0a libfaim/aim_info.c --- a/libfaim/aim_info.c Thu Jan 04 23:29:52 2001 +0000 +++ b/libfaim/aim_info.c Fri Jan 05 00:17:43 2001 +0000 @@ -126,7 +126,7 @@ /* Games */ {0x09, 0x46, 0x13, 0x4a, 0x4c, 0x7f, 0x11, 0xd1, - 0x22, 0x82, 0x44, 0x45, 0x53, 0x54, 0x00, 0x00}, + 0x82, 0x22, 0x44, 0x45, 0x53, 0x54, 0x00, 0x00}, }; faim_internal unsigned short aim_getcap(unsigned char *capblock, int buflen) @@ -153,7 +153,10 @@ } } if (!identified) { - printf("faim: unknown capability!\n"); + printf("faim: unknown capability "); + for (y = 0; y < 0x10; y++) + printf("%02x ", capblock[offset+y]); + printf("\n"); ret |= 0xff00; } @@ -374,6 +377,8 @@ break; outinfo->capabilities = aim_getcap(buf+i+4, len); + if (outinfo->capabilities & 0xff00) + printf("%s\n", outinfo->sn); } break; diff -r 569835fcabc3 -r aedeb1218a0a plugins/autorecon.c --- a/plugins/autorecon.c Thu Jan 04 23:29:52 2001 +0000 +++ b/plugins/autorecon.c Fri Jan 05 00:17:43 2001 +0000 @@ -4,10 +4,11 @@ extern GtkWidget *imaway; -static int recon; static int away_state; static int forced_off = 0; -static struct away_message *last_away; +static struct away_message *last_away = NULL; +GSList *reconnects = NULL; +GSList *recontim = NULL; char *name() { return "Auto Reconnect"; @@ -17,23 +18,39 @@ return "When AOL kicks you off, this auto-reconnects you."; } -void do_signon(char *name) { - struct aim_user *u = find_user(name, -1); - g_free(name); - gtk_timeout_remove(recon); - if (!u) return; - serv_login(u); - forced_off = 0; +static void now_online(struct gaim_connection *gc, void *m) { + gint place; + guint recon; + if (!g_slist_find(reconnects, gc->user)) + return; + place = g_slist_index(reconnects, gc->user); + recon = (guint)g_slist_nth(recontim, place); + reconnects = g_slist_remove(reconnects, gc->user); + recontim = g_slist_remove(recontim, (void *)recon); if (away_state) do_away_message(NULL, last_away); } -void reconnect(struct gaim_connection *gc, void *m) { - char *name = g_strdup(gc->username); - recon = gtk_timeout_add(8000, (GtkFunction)do_signon, name); +static void do_signon(struct aim_user *u) { + gint place; + guint recon; + place = g_slist_index(reconnects, u); + recon = (guint)g_slist_nth(recontim, place); + gtk_timeout_remove(recon); + forced_off = 0; + serv_login(u); +} + +static void reconnect(struct gaim_connection *gc, void *m) { + guint recon; + if (g_slist_find(reconnects, gc->user)) + return; + recon = gtk_timeout_add(8000, (GtkFunction)do_signon, gc->user); + reconnects = g_slist_append(reconnects, gc->user); + recontim = g_slist_append(recontim, (void *)recon); forced_off = 1; } -void away_toggle(void *m) { +static void away_toggle(void *m) { if ((int)m == 1) { last_away = awaymessage; away_state = 1; @@ -51,6 +68,7 @@ gaim_signal_connect(handle, event_away, away_toggle, (void *)1); gaim_signal_connect(handle, event_back, away_toggle, (void *)0); gaim_signal_connect(handle, event_signoff, reconnect, NULL); + gaim_signal_connect(handle, event_signon, now_online, NULL); return NULL; }