Thu, 14 Jun 2007 19:32:06 +0000
I think this will fix the problem that elb had where bonjour (and probably other accounts too) were signing on initially when -n was specified.
| libpurple/idle.c | file | annotate | diff | comparison | revisions |
--- a/libpurple/idle.c Thu Jun 14 18:20:53 2007 +0000 +++ b/libpurple/idle.c Thu Jun 14 19:32:06 2007 +0000 @@ -300,6 +300,14 @@ return &handle; } +static gboolean _do_purple_idle_touch_cb(gpointer data) +{ + purple_idle_touch(); + + return FALSE; +} + + void purple_idle_init() { @@ -319,7 +327,10 @@ purple_prefs_connect_callback(purple_idle_get_handle(), "/purple/away/idle_reporting", idle_reporting_cb, NULL); - purple_idle_touch(); + /* Initialize the idleness asynchronously so it doesn't check idleness, + * and potentially try to change the status before the UI is initialized */ + g_idle_add(_do_purple_idle_touch_cb, NULL); + } void