Add auto-away to plugin-tray

This commit is contained in:
TingPing
2012-12-20 19:39:52 -05:00
parent 76680ae41b
commit 4524367cc0
4 changed files with 7 additions and 0 deletions

View File

@@ -394,12 +394,16 @@ tray_toggle_visibility (gboolean force_hide)
if (force_hide || GTK_WIDGET_VISIBLE (win))
#endif
{
if (prefs.hex_gui_tray_away)
hexchat_command (ph, "ALLSERV AWAY");
gtk_window_get_position (win, &x, &y);
screen = gtk_window_get_screen (win);
gtk_widget_hide (GTK_WIDGET (win));
}
else
{
if (prefs.hex_gui_tray_away)
hexchat_command (ph, "ALLSERV BACK");
gtk_window_set_screen (win, screen);
gtk_window_move (win, x, y);
gtk_widget_show (GTK_WIDGET (win));