Mercurial > pidgin
comparison src/idle.c @ 1446:38f712e75836
[gaim-migrate @ 1456]
i think this should work more better
committer: Tailor Script <tailor@pidgin.im>
author | Eric Warmenhoven <eric@warmenhoven.org> |
---|---|
date | Tue, 30 Jan 2001 02:27:35 +0000 |
parents | 9f356885a77a |
children | 024f9250ba63 |
comparison
equal
deleted
inserted
replaced
1445:aebbe67e48cb | 1446:38f712e75836 |
---|---|
66 } else | 66 } else |
67 #endif /* USE_SCREENSAVER */ | 67 #endif /* USE_SCREENSAVER */ |
68 idle_time = t - gc->lastsent; | 68 idle_time = t - gc->lastsent; |
69 | 69 |
70 if ((general_options & OPT_GEN_AUTO_AWAY) && (idle_time > (60 * auto_away)) && | 70 if ((general_options & OPT_GEN_AUTO_AWAY) && (idle_time > (60 * auto_away)) && |
71 (!gc->away) && (!gc->is_auto_away)) { | 71 (!gc->is_auto_away)) { |
72 debug_printf("making %s away automatically\n", gc->username); | 72 debug_printf("making %s away automatically\n", gc->username); |
73 set_default_away((GtkWidget*)NULL, (gpointer)g_slist_index(away_messages, default_away)); | 73 set_default_away((GtkWidget*)NULL, (gpointer)g_slist_index(away_messages, default_away)); |
74 serv_set_away(gc, GAIM_AWAY_CUSTOM, default_away->message); | 74 if (!gc->away) { |
75 if (g_slist_length(connections) == 1) | |
76 do_away_message(NULL, default_away); | |
77 else | |
78 serv_set_away(gc, GAIM_AWAY_CUSTOM, default_away->message); | |
79 } | |
75 gc->is_auto_away = TRUE; | 80 gc->is_auto_away = TRUE; |
76 } else if (gc->is_auto_away && idle_time < 60 * auto_away) { | 81 } else if (gc->is_auto_away && idle_time < 60 * auto_away) { |
77 gc->is_auto_away = FALSE; | 82 gc->is_auto_away = FALSE; |
78 if (awaymessage == NULL) { | 83 if (awaymessage == NULL) { |
79 debug_printf("removing auto-away message for %s\n", gc->username); | 84 debug_printf("removing auto-away message for %s\n", gc->username); |