diff options
author | Tiago Cunha <tcunha@gmx.com> | 2012-05-30 13:49:45 +0000 |
---|---|---|
committer | Tiago Cunha <tcunha@gmx.com> | 2012-05-30 13:49:45 +0000 |
commit | bf4b02cea2f4483c07de16e5d408adf3421c8c4f (patch) | |
tree | 39de7a2418bfe6576fdf575cc1e4dacecae4def9 /cmd-choose-window.c | |
parent | e96d51424745d4a4a9574c39c3777e8c05311c22 (diff) | |
download | rtmux-bf4b02cea2f4483c07de16e5d408adf3421c8c4f.tar.gz rtmux-bf4b02cea2f4483c07de16e5d408adf3421c8c4f.tar.bz2 rtmux-bf4b02cea2f4483c07de16e5d408adf3421c8c4f.zip |
Sync OpenBSD patchset 1130:
Add pane title to choose-window template and use the right index for the
pane, from Romain Francoise.
Diffstat (limited to 'cmd-choose-window.c')
-rw-r--r-- | cmd-choose-window.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/cmd-choose-window.c b/cmd-choose-window.c index b4ac3305..78fdacae 100644 --- a/cmd-choose-window.c +++ b/cmd-choose-window.c @@ -72,7 +72,7 @@ cmd_choose_window_exec(struct cmd *self, struct cmd_ctx *ctx) return (0); if ((template = args_get(args, 'F')) == NULL) - template = DEFAULT_WINDOW_TEMPLATE; + template = DEFAULT_WINDOW_TEMPLATE " \"#{pane_title}\""; cur = idx = 0; RB_FOREACH(wm, winlinks, &s->windows) { @@ -84,9 +84,10 @@ cmd_choose_window_exec(struct cmd *self, struct cmd_ctx *ctx) format_add(ft, "line", "%u", idx); format_session(ft, s); format_winlink(ft, s, wm); + format_window_pane(ft, wm->window->active); line = format_expand(ft, template); - window_choose_add(wl->window->active, idx, "%s", line); + window_choose_add(wl->window->active, wm->idx, "%s", line); xfree(line); format_free(ft); |