diff options
author | Nicholas Marriott <nicm@cvs.openbsd.org> | 2009-07-14 16:52:51 +0000 |
---|---|---|
committer | Nicholas Marriott <nicm@cvs.openbsd.org> | 2009-07-14 16:52:51 +0000 |
commit | 903f988cb5e188297e39b912183ecd5767e3e2b7 (patch) | |
tree | 65626e1d7e5901639fa949c8dd0e0e191ef5ecf4 | |
parent | 133dc4affb2c0159f4cfb20438099effa7828d17 (diff) |
Don't accept input to a window if it not visible.
-rw-r--r-- | usr.bin/tmux/window.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.bin/tmux/window.c b/usr.bin/tmux/window.c index f3ecc658a82..dbe8275e169 100644 --- a/usr.bin/tmux/window.c +++ b/usr.bin/tmux/window.c @@ -1,4 +1,4 @@ -/* $OpenBSD: window.c,v 1.10 2009/07/14 07:23:36 nicm Exp $ */ +/* $OpenBSD: window.c,v 1.11 2009/07/14 16:52:50 nicm Exp $ */ /* * Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net> @@ -580,7 +580,7 @@ window_pane_parse(struct window_pane *wp) void window_pane_key(struct window_pane *wp, struct client *c, int key) { - if (wp->fd == -1) + if (wp->fd == -1 || !window_pane_visible(wp)) return; if (wp->mode != NULL) { @@ -594,7 +594,7 @@ void window_pane_mouse( struct window_pane *wp, struct client *c, u_char b, u_char x, u_char y) { - if (wp->fd == -1) + if (wp->fd == -1 || !window_pane_visible(wp)) return; /* XXX convert from 1-based? */ |