summaryrefslogtreecommitdiffstats
path: root/usr.bin/tmux/server-client.c
diff options
context:
space:
mode:
authornicm <nicm@openbsd.org>2013-03-24 09:57:59 +0000
committernicm <nicm@openbsd.org>2013-03-24 09:57:59 +0000
commitb4a3311ed2e18a290144fc9d4b326eec29e85f98 (patch)
treef860790228b1e2701b5f74a9c885edd023ed22ba /usr.bin/tmux/server-client.c
parentAdd a -o option to set-option to prevent setting an option already set, (diff)
downloadwireguard-openbsd-b4a3311ed2e18a290144fc9d4b326eec29e85f98.tar.xz
wireguard-openbsd-b4a3311ed2e18a290144fc9d4b326eec29e85f98.zip
Add resize-pane -Z to temporary zoom the active pane to occupy the full
window or unzoom (restored to the normal layout) if it already zoomed, bound to C-b z by default. The pane is unzoomed on pretty much any excuse whatsoever. We considered making this a new layout but the requirements are quite different from layouts so decided it is better as a special case. Each current layout cell is saved, a temporary one-cell layout generated and all except the active pane set to NULL. Prompted by suggestions and scripts from several. Thanks to Aaron Jensen and Thiago Padilha for testing an earlier version.
Diffstat (limited to 'usr.bin/tmux/server-client.c')
-rw-r--r--usr.bin/tmux/server-client.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/usr.bin/tmux/server-client.c b/usr.bin/tmux/server-client.c
index 88244dbc9e2..edadf6f45bd 100644
--- a/usr.bin/tmux/server-client.c
+++ b/usr.bin/tmux/server-client.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: server-client.c,v 1.94 2013/03/24 09:54:10 nicm Exp $ */
+/* $OpenBSD: server-client.c,v 1.95 2013/03/24 09:57:59 nicm Exp $ */
/*
* Copyright (c) 2009 Nicholas Marriott <nicm@users.sourceforge.net>
@@ -384,6 +384,7 @@ server_client_handle_key(struct client *c, int key)
if (c->flags & CLIENT_IDENTIFY && key >= '0' && key <= '9') {
if (c->flags & CLIENT_READONLY)
return;
+ window_unzoom(w);
wp = window_pane_at_index(w, key - '0');
if (wp != NULL && window_pane_visible(wp))
window_set_active_pane(w, wp);