# HG changeset patch # User Eric Warmenhoven # Date 1001654236 0 # Node ID 427ccd7dfdd21a421b2bbb436dc9e3ba74985c55 # Parent 6f83c22d9e7052dc66301236172a08672200d41b [gaim-migrate @ 2394] server.c: 30 / 935 3 % committer: Tailor Script diff -r 6f83c22d9e70 -r 427ccd7dfdd2 src/gaim.h --- a/src/gaim.h Fri Sep 28 02:16:34 2001 +0000 +++ b/src/gaim.h Fri Sep 28 05:17:16 2001 +0000 @@ -613,7 +613,7 @@ extern gchar *strip_html(gchar *); /* Functions in idle.c */ -extern gint check_idle(struct gaim_connection *); +extern gint check_idle(gpointer); /* Functions in util.c */ extern char *normalize(const char *); diff -r 6f83c22d9e70 -r 427ccd7dfdd2 src/idle.c --- a/src/idle.c Fri Sep 28 02:16:34 2001 +0000 +++ b/src/idle.c Fri Sep 28 05:17:16 2001 +0000 @@ -38,8 +38,9 @@ #include "prpl.h" -gint check_idle(struct gaim_connection *gc) +gint check_idle(gpointer data) { + struct gaim_connection *gc = data; time_t t; #ifdef USE_SCREENSAVER static XScreenSaverInfo *mit_info = NULL; diff -r 6f83c22d9e70 -r 427ccd7dfdd2 src/server.c --- a/src/server.c Fri Sep 28 02:16:34 2001 +0000 +++ b/src/server.c Fri Sep 28 05:17:16 2001 +0000 @@ -31,13 +31,6 @@ #include #include #include -#include -#ifdef USE_SCREENSAVER -#include -#include -#include -#endif /* USE_SCREENSAVER */ -extern int gaim_caps; #include "prpl.h" #include "multi.h" #include "gaim.h" @@ -107,7 +100,7 @@ if (gc->idle_timer > 0) g_source_remove(gc->idle_timer); - gc->idle_timer = g_timeout_add(20000, (GtkFunction)check_idle, gc); + gc->idle_timer = g_timeout_add(20000, check_idle, gc); serv_touch_idle(gc); time(&gc->login_time); @@ -656,7 +649,6 @@ g_snprintf(b->name, sizeof(b->name), "%s", name); handle_buddy_rename(b, who); g_free(who); - /*gtk_label_set_text(GTK_LABEL(b->label), b->name); */ /* okay lets save the new config... */ @@ -708,18 +700,10 @@ set_buddy(gc, b); } -static -void close_warned(GtkWidget *w, GtkWidget *w2) -{ - gtk_widget_destroy(w2); -} - - void serv_got_eviled(struct gaim_connection *gc, char *name, int lev) { char buf2[1024]; - GtkWidget *d, *label, *close; plugin_event(event_warned, gc, name, (void *)lev, 0); @@ -733,20 +717,7 @@ g_snprintf(buf2, sizeof(buf2), "%s has just been warned by %s.\nYour new warning level is %d%%", gc->username, ((name == NULL)? "an anonymous person" : name), lev); - d = gtk_dialog_new(); - gtk_widget_realize(d); - aol_icon(d->window); - - label = gtk_label_new(buf2); - gtk_widget_show(label); - close = picture_button(d, _("Close"), cancel_xpm); - gtk_widget_show(close); - gtk_box_pack_start(GTK_BOX(GTK_DIALOG(d)->vbox), label, FALSE, FALSE, 5); - gtk_box_pack_start(GTK_BOX(GTK_DIALOG(d)->action_area), close, FALSE, FALSE, 5); - - gtk_window_set_title(GTK_WINDOW(d), "Warned"); - gtk_signal_connect(GTK_OBJECT(close), "clicked", GTK_SIGNAL_FUNC(close_warned), d); - gtk_widget_show(d); + do_error_dialog(_("Warned"), buf2); } @@ -955,7 +926,7 @@ { if (on && !gc->keepalive && blist) { debug_printf("allowing NOP\n"); - gc->keepalive = g_timeout_add(60000, (GtkFunction)send_keepalive, gc); + gc->keepalive = g_timeout_add(60000, send_keepalive, gc); } else if (!on && gc->keepalive > 0) { debug_printf("removing NOP\n"); g_source_remove(gc->keepalive);