about summary refs log tree commit diff stats
path: root/src/ui
diff options
context:
space:
mode:
authorDominik Heidler <dominik@heidler.eu>2016-04-16 16:29:32 +0200
committerDominik Heidler <dominik@heidler.eu>2016-04-16 16:29:32 +0200
commit4cb1d73a8358f660056156b5632e8c41659eb6e0 (patch)
tree97c905d2651768030f6befa4e17c0d3d72e74497 /src/ui
parent6cc04bc3ba85415e6ec532ddf60738961a3a9560 (diff)
downloadprofani-tty-4cb1d73a8358f660056156b5632e8c41659eb6e0.tar.gz
Make tray icon configurable using /tray cmd
Diffstat (limited to 'src/ui')
-rw-r--r--src/ui/console.c14
-rw-r--r--src/ui/ui.h3
2 files changed, 17 insertions, 0 deletions
diff --git a/src/ui/console.c b/src/ui/console.c
index c104e21b..73cfbfd1 100644
--- a/src/ui/console.c
+++ b/src/ui/console.c
@@ -1182,6 +1182,17 @@ cons_flash_setting(void)
         cons_show("Terminal flash (/flash)             : OFF");
 }
 
+#ifdef HAVE_GTK
+void
+cons_tray_setting(void)
+{
+    if (prefs_get_boolean(PREF_TRAY))
+        cons_show("Tray icon (/tray)             : ON");
+    else
+        cons_show("Tray icon (/tray)             : OFF");
+}
+#endif
+
 void
 cons_splash_setting(void)
 {
@@ -1497,6 +1508,9 @@ cons_show_ui_prefs(void)
     cons_theme_setting();
     cons_beep_setting();
     cons_flash_setting();
+#ifdef HAVE_GTK
+    cons_tray_setting();
+#endif
     cons_splash_setting();
     cons_wrap_setting();
     cons_winstidy_setting();
diff --git a/src/ui/ui.h b/src/ui/ui.h
index 924ba33c..09215595 100644
--- a/src/ui/ui.h
+++ b/src/ui/ui.h
@@ -284,6 +284,9 @@ void cons_privileges_setting(void);
 void cons_beep_setting(void);
 void cons_console_setting(void);
 void cons_flash_setting(void);
+#ifdef HAVE_GTK
+void cons_tray_setting(void);
+#endif
 void cons_splash_setting(void);
 void cons_encwarn_setting(void);
 void cons_tlsshow_setting(void);