summaryrefslogtreecommitdiff
path: root/usr.bin/tmux
diff options
context:
space:
mode:
authorNicholas Marriott <nicm@cvs.openbsd.org>2012-05-05 18:48:32 +0000
committerNicholas Marriott <nicm@cvs.openbsd.org>2012-05-05 18:48:32 +0000
commitda9b777fe35bfcbc4be27ad117391977c0e98a31 (patch)
tree5ba4234f607ef23b9c3c8f7c12614df99535387e /usr.bin/tmux
parentf5e612d29e720719519414a1f4afa54f1fcab09d (diff)
Only enter copy mode on scroll up, from Ailin Nemui.
Diffstat (limited to 'usr.bin/tmux')
-rw-r--r--usr.bin/tmux/input-keys.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/usr.bin/tmux/input-keys.c b/usr.bin/tmux/input-keys.c
index beb819b96f6..07018cb320e 100644
--- a/usr.bin/tmux/input-keys.c
+++ b/usr.bin/tmux/input-keys.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: input-keys.c,v 1.24 2012/04/01 20:56:47 nicm Exp $ */
+/* $OpenBSD: input-keys.c,v 1.25 2012/05/05 18:48:31 nicm Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
@@ -223,7 +223,8 @@ input_mouse(struct window_pane *wp, struct mouse_event *m)
return;
}
- if (options_get_number(&wp->window->options, "mode-mouse") == 1) {
+ if ((m->b & 3) != 1 &&
+ options_get_number(&wp->window->options, "mode-mouse") == 1) {
if (window_pane_set_mode(wp, &window_copy_mode) == 0) {
window_copy_init_from_pane(wp);
if (wp->mode->mouse != NULL)