1
0
mirror of https://github.com/Tha14/toxic.git synced 2025-07-01 13:26:44 +02:00

Add notification counters to bottom tab

A counter now increments in the bottom bar for unfocused windows showing how
many unread messages are pending. Tabs with no pending messages show [*]
instead of their index (showing the index is useless and somewhat confusing)
This commit is contained in:
jfreegman
2020-11-21 11:25:41 -05:00
parent da2889f3ab
commit 9d65997871
4 changed files with 15 additions and 3 deletions

View File

@ -126,6 +126,8 @@ static void tab_notify(ToxWindow *self, uint64_t flags)
} else if ((flags & NT_WNDALERT_2) && (!self->alert || self->alert > WINDOW_ALERT_1)) {
self->alert = WINDOW_ALERT_2;
}
++self->pending_messages;
}
static bool notifications_are_disabled(uint64_t flags)