=== modified file 'indicator.c' --- indicator.c 2010-02-08 14:04:15 +0000 +++ indicator.c 2010-03-29 07:10:33 +0000 @@ -53,7 +53,7 @@ static void add_indicator (const gchar *channel); static void really_activate_window (GtkWindow *win); static gchar *focused; - +static gboolean hidden = FALSE; static void indicator_display (gpointer indicator, guint timestamp, const gchar *channel) @@ -86,11 +86,17 @@ static void server_display (IndicateServer * indicate_server, guint timestamp, gpointer data) { - GtkWindow *win = (GtkWindow *)xchat_get_info (ph, "win_ptr"); - really_activate_window (GTK_WINDOW (win)); - /* gtk_window_present_with_time(GTK_WINDOW (win), timestamp); */ - g_debug ("INDICATOR: Showing the window"); - /* XXX: Should clear all indicators */ + if (hidden) { + GtkWindow *win = (GtkWindow *)xchat_get_info (ph, "win_ptr"); + really_activate_window (GTK_WINDOW (win)); + xchat_command (ph, "GUI SHOW"); + /* gtk_window_present_with_time(GTK_WINDOW (win), timestamp); */ + g_debug ("INDICATOR: Showing the window"); + /* XXX: Should clear all indicators */ + } else { + xchat_command (ph, "GUI HIDE"); + } + hidden = !hidden; } static void