aboutsummaryrefslogtreecommitdiff
path: root/status.c
diff options
context:
space:
mode:
authorTiago Cunha <tcunha@gmx.com>2011-01-07 16:55:40 +0000
committerTiago Cunha <tcunha@gmx.com>2011-01-07 16:55:40 +0000
commit30f6d9b167907783122869100046954e52c07694 (patch)
tree16dfc3e30982c4155458349b9b6fb3e5bf8da5b0 /status.c
parent1cb579d0fdf5eab42866c3d2d01ab6f2f87b3cbb (diff)
downloadrtmux-30f6d9b167907783122869100046954e52c07694.tar.gz
rtmux-30f6d9b167907783122869100046954e52c07694.tar.bz2
rtmux-30f6d9b167907783122869100046954e52c07694.zip
Sync OpenBSD patchset 813:
Add a function to create window flags rather than doing the same thing in two places. From Thomas Adam.
Diffstat (limited to 'status.c')
-rw-r--r--status.c19
1 files changed, 3 insertions, 16 deletions
diff --git a/status.c b/status.c
index b694068a..9c29c818 100644
--- a/status.c
+++ b/status.c
@@ -1,4 +1,4 @@
-/* $Id: status.c,v 1.154 2011-01-07 14:32:26 tcunha Exp $ */
+/* $Id: status.c,v 1.155 2011-01-07 16:55:40 tcunha Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
@@ -393,21 +393,8 @@ status_replace1(struct client *c,struct winlink *wl,
ptr = wl->window->name;
goto do_replace;
case 'F':
- tmp[0] = ' ';
- if (wl->flags & WINLINK_CONTENT)
- tmp[0] = '+';
- else if (wl->flags & WINLINK_BELL)
- tmp[0] = '!';
- else if (wl->flags & WINLINK_ACTIVITY)
- tmp[0] = '#';
- else if (wl->flags & WINLINK_SILENCE)
- tmp[0] = '~';
- else if (wl == s->curw)
- tmp[0] = '*';
- else if (wl == TAILQ_FIRST(&s->lastw))
- tmp[0] = '-';
- tmp[1] = '\0';
- ptr = tmp;
+ ptr = window_printable_flags(s, wl);
+ freeptr = ptr;
goto do_replace;
case '[':
/*