diff options
author | Thomas Adam <thomas@xteddy.org> | 2018-06-25 19:02:24 +0100 |
---|---|---|
committer | Thomas Adam <thomas@xteddy.org> | 2018-06-25 19:02:24 +0100 |
commit | cb77c2aa78c77b0dada2964e140045e85ce53dbb (patch) | |
tree | cd0c68a320a279aab5a1f25ae300a49fd76e4566 | |
parent | 94712a8b0df6d5de21409e762e462371fb5e8497 (diff) | |
parent | 0c94c3fbee3df39293de8b7fd957392251113a74 (diff) | |
download | rtmux-cb77c2aa78c77b0dada2964e140045e85ce53dbb.tar.gz rtmux-cb77c2aa78c77b0dada2964e140045e85ce53dbb.tar.bz2 rtmux-cb77c2aa78c77b0dada2964e140045e85ce53dbb.zip |
Merge branch 'obsd-master'
-rw-r--r-- | cmd-select-pane.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/cmd-select-pane.c b/cmd-select-pane.c index 790a1a5b..a2345fe1 100644 --- a/cmd-select-pane.c +++ b/cmd-select-pane.c @@ -69,6 +69,11 @@ cmd_select_pane_exec(struct cmd *self, struct cmdq_item *item) if (self->entry == &cmd_last_pane_entry || args_has(args, 'l')) { lastwp = w->last; + if (lastwp == NULL && window_count_panes(w) == 2) { + lastwp = TAILQ_PREV(w->active, window_panes, entry); + if (lastwp == NULL) + lastwp = TAILQ_NEXT(w->active, entry); + } if (lastwp == NULL) { cmdq_error(item, "no last pane"); return (CMD_RETURN_ERROR); |