version 1.16, 2010/12/20 00:03:55 |
version 1.17, 2010/12/30 21:35:17 |
|
|
struct winlink *wl, *wm; |
struct winlink *wl, *wm; |
struct window *w; |
struct window *w; |
u_int idx, cur; |
u_int idx, cur; |
char flag, *title; |
char *flags, *title; |
const char *left, *right; |
const char *left, *right; |
|
|
if (ctx->curclient == NULL) { |
if (ctx->curclient == NULL) { |
|
|
cur = idx; |
cur = idx; |
idx++; |
idx++; |
|
|
flag = ' '; |
flags = window_printable_flags(s, wm); |
if (wm->flags & WINLINK_ACTIVITY) |
|
flag = '#'; |
|
else if (wm->flags & WINLINK_BELL) |
|
flag = '!'; |
|
else if (wm->flags & WINLINK_CONTENT) |
|
flag = '+'; |
|
else if (wm->flags & WINLINK_SILENCE) |
|
flag = '~'; |
|
else if (wm == s->curw) |
|
flag = '*'; |
|
else if (wm == TAILQ_FIRST(&s->lastw)) |
|
flag = '-'; |
|
|
|
title = w->active->screen->title; |
title = w->active->screen->title; |
if (wm == wl) |
if (wm == wl) |
title = w->active->base.title; |
title = w->active->base.title; |
|
|
left = right = ""; |
left = right = ""; |
|
|
window_choose_add(wl->window->active, |
window_choose_add(wl->window->active, |
wm->idx, "%3d: %s%c [%ux%u] (%u panes%s)%s%s%s", |
wm->idx, "%3d: %s%s [%ux%u] (%u panes%s)%s%s%s", |
wm->idx, w->name, flag, w->sx, w->sy, window_count_panes(w), |
wm->idx, w->name, flags, w->sx, w->sy, window_count_panes(w), |
w->active->fd == -1 ? ", dead" : "", |
w->active->fd == -1 ? ", dead" : "", |
left, title, right); |
left, title, right); |
|
|
|
xfree(flags); |
} |
} |
|
|
cdata = xmalloc(sizeof *cdata); |
cdata = xmalloc(sizeof *cdata); |