From 019d6da3122ec23de341952fc4019c4c2d4a66a1 Mon Sep 17 00:00:00 2001 From: nicm Date: Tue, 2 Feb 2021 13:03:03 +0000 Subject: [PATCH] Fix popup mouse position. --- usr.bin/tmux/popup.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/usr.bin/tmux/popup.c b/usr.bin/tmux/popup.c index 79fc6709881..e64070a5a28 100644 --- a/usr.bin/tmux/popup.c +++ b/usr.bin/tmux/popup.c @@ -1,4 +1,4 @@ -/* $OpenBSD: popup.c,v 1.20 2020/09/22 06:44:52 nicm Exp $ */ +/* $OpenBSD: popup.c,v 1.21 2021/02/02 13:03:03 nicm Exp $ */ /* * Copyright (c) 2020 Nicholas Marriott @@ -323,8 +323,8 @@ popup_key_cb(struct client *c, struct key_event *event) return (0); if (KEYC_IS_MOUSE(event->key)) { /* Must be inside, checked already. */ - if (!input_key_get_mouse(&pd->s, m, m->x - pd->px, - m->y - pd->py, &buf, &len)) + if (!input_key_get_mouse(&pd->s, m, m->x - pd->px - 1, + m->y - pd->py - 1, &buf, &len)) return (0); bufferevent_write(job_get_event(pd->job), buf, len); return (0); -- 2.20.1