about summary refs log tree commit diff
path: root/ui.c
diff options
context:
space:
mode:
authorJune McEnroe <june@causal.agency>2021-05-28 20:38:43 -0400
committerJune McEnroe <june@causal.agency>2021-05-28 20:40:25 -0400
commitf559322224cc3bfa6c1d37631fb6dc5fa93449b9 (patch)
treeaf54593bc7b2fa0f28df12345b97a523a10eeb56 /ui.c
parentImprove missing param behavior for /msg, /whois, /ns, /cs (diff)
downloadcatgirl-f559322224cc3bfa6c1d37631fb6dc5fa93449b9.tar.gz
catgirl-f559322224cc3bfa6c1d37631fb6dc5fa93449b9.zip
List windows with /window 1.8
Reuse the /window command to preserve /wi abbreviation.
Diffstat (limited to 'ui.c')
-rw-r--r--ui.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/ui.c b/ui.c
index add6eb3..6449e27 100644
--- a/ui.c
+++ b/ui.c
@@ -797,6 +797,16 @@ static void inputUpdate(void) {
 	wmove(input, y, x);
 }
 
+void uiWindows(void) {
+	for (uint num = 0; num < windows.len; ++num) {
+		const struct Window *window = windows.ptrs[num];
+		uiFormat(
+			Network, Warm, NULL, "\3%02d%u %s",
+			idColors[window->id], num, idNames[window->id]
+		);
+	}
+}
+
 static void windowShow(uint num) {
 	if (num != windows.show) {
 		windows.swap = windows.show;