summaryrefslogtreecommitdiffstats
path: root/tty.c
diff options
context:
space:
mode:
authornicm <nicm>2022-06-03 08:09:16 +0000
committernicm <nicm>2022-06-03 08:09:16 +0000
commit3edda3c5e71d634efd8e1e849328a68fb9da37de (patch)
tree6d4548ca0fb7645969b41dc53fcfe37b2cbab9cb /tty.c
parent18838fbc877b5c003449fa10df353405c024f0f5 (diff)
Do not unintentionally turn off all mouse mode when button is also present.
Diffstat (limited to 'tty.c')
-rw-r--r--tty.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tty.c b/tty.c
index ea10e61e..49cf9795 100644
--- a/tty.c
+++ b/tty.c
@@ -814,7 +814,7 @@ tty_update_mode(struct tty *tty, int mode, struct screen *s)
tty_puts(tty, "\033[?1006h");
if (mode & MODE_MOUSE_ALL)
tty_puts(tty, "\033[?1000h\033[?1002h\033[?1003h");
- if (mode & MODE_MOUSE_BUTTON)
+ else if (mode & MODE_MOUSE_BUTTON)
tty_puts(tty, "\033[?1000h\033[?1002h");
else if (mode & MODE_MOUSE_STANDARD)
tty_puts(tty, "\033[?1000h");