aboutsummaryrefslogtreecommitdiff
path: root/tty.c
diff options
context:
space:
mode:
authorNicholas Marriott <nicholas.marriott@gmail.com>2020-05-14 11:18:19 +0100
committerNicholas Marriott <nicholas.marriott@gmail.com>2020-05-14 11:18:19 +0100
commit0bdbf47ef946b3535cc32b45ea8d971de5baddb5 (patch)
treea44b650fc7eb232083f25e070f243899ed9cbedc /tty.c
parent12eceaf2b3ef2b028a55d8ad11951be700be0446 (diff)
downloadrtmux-0bdbf47ef946b3535cc32b45ea8d971de5baddb5.tar.gz
rtmux-0bdbf47ef946b3535cc32b45ea8d971de5baddb5.tar.bz2
rtmux-0bdbf47ef946b3535cc32b45ea8d971de5baddb5.zip
Add a client flag 'active-pane' which stores the active pane in the client and
allows it to be changed independently from the real active pane stored in the window. This is can be used with session groups which allow an independent current window (although it would be nice to have a flag for this too and remove session groups). The client active pane is only really useful interactively, many things (hooks, window-style, zooming) still use the window active pane.
Diffstat (limited to 'tty.c')
-rw-r--r--tty.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/tty.c b/tty.c
index a1e2f2c6..a4f2acee 100644
--- a/tty.c
+++ b/tty.c
@@ -693,8 +693,7 @@ tty_update_mode(struct tty *tty, int mode, struct screen *s)
}
if (s != NULL && tty->cstyle != s->cstyle) {
if (tty_term_has(tty->term, TTYC_SS)) {
- if (s->cstyle == 0 &&
- tty_term_has(tty->term, TTYC_SE))
+ if (s->cstyle == 0 && tty_term_has(tty->term, TTYC_SE))
tty_putcode(tty, TTYC_SE);
else
tty_putcode1(tty, TTYC_SS, s->cstyle);
@@ -792,7 +791,7 @@ tty_window_offset1(struct tty *tty, u_int *ox, u_int *oy, u_int *sx, u_int *sy)
{
struct client *c = tty->client;
struct window *w = c->session->curw->window;
- struct window_pane *wp = w->active;
+ struct window_pane *wp = server_client_get_pane(c);
u_int cx, cy, lines;
lines = status_line_size(c);