about summary refs log tree commit diff stats
path: root/src/ui
diff options
context:
space:
mode:
authorMichael Vetter <jubalh@iodoru.org>2023-04-18 14:43:01 +0200
committerGitHub <noreply@github.com>2023-04-18 14:43:01 +0200
commit4933d4e4f3d1cc8ee308c1bb6bfc4c13ec64ac57 (patch)
tree1fed6ab534a857572c0732fe5c9dad73af4617dd /src/ui
parentf51dc019bc08e41fa4564d465136522648a7a663 (diff)
parentbed5c02c0dde0fe3cd8eb6018322a78b4441e22a (diff)
downloadprofani-tty-4933d4e4f3d1cc8ee308c1bb6bfc4c13ec64ac57.tar.gz
Merge pull request #1827 from H3rnand3zzz/feature/sessions-alarm
New Feature: Session Alarm
Diffstat (limited to 'src/ui')
-rw-r--r--src/ui/console.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/ui/console.c b/src/ui/console.c
index d26e559f..b57ac6f4 100644
--- a/src/ui/console.c
+++ b/src/ui/console.c
@@ -1067,6 +1067,9 @@ cons_show_account(ProfAccount* account)
     if (account->client) {
         cons_show("Client name       : %s", account->client);
     }
+    if (account->max_sessions > 0) {
+        cons_show("Max sessions alarm: %d", account->max_sessions);
+    }
     if (account->theme) {
         cons_show("Theme             : %s", account->theme);
     }
@@ -1123,11 +1126,12 @@ cons_show_account(ProfAccount* account)
 
     if ((connection_get_status() == JABBER_CONNECTED) && (g_strcmp0(session_get_account_name(), account->name) == 0)) {
         GList* resources = connection_get_available_resources();
+        int resources_count = connection_count_available_resources();
         GList* ordered_resources = NULL;
 
         GList* curr = resources;
         if (curr) {
-            win_println(console, THEME_DEFAULT, "-", "Resources:");
+            win_println(console, THEME_DEFAULT, "-", "Resources (%u):", resources_count);
 
             // sort in order of availability
             while (curr) {