From 302fe310d00d29536b2308ab55d1587cb3708825 Mon Sep 17 00:00:00 2001 From: nicm Date: Mon, 26 Oct 2015 17:17:06 +0000 Subject: [PATCH] Some extra logging of where keys are actually going. --- usr.bin/tmux/input-keys.c | 7 ++++--- usr.bin/tmux/server-client.c | 4 +++- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/usr.bin/tmux/input-keys.c b/usr.bin/tmux/input-keys.c index f7fefb2578c..46f657d81a4 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.43 2015/04/21 15:21:41 nicm Exp $ */ +/* $OpenBSD: input-keys.c,v 1.44 2015/10/26 17:17:06 nicm Exp $ */ /* * Copyright (c) 2007 Nicholas Marriott @@ -145,7 +145,8 @@ input_key(struct window_pane *wp, int key, struct mouse_event *m) char *out; u_char ch; - log_debug("writing key 0x%x (%s)", key, key_string_lookup_key(key)); + log_debug("writing key 0x%x (%s) to %%%u", key, + key_string_lookup_key(key), wp->id); /* If this is a mouse key, pass off to mouse function. */ if (KEYC_IS_MOUSE(key)) { @@ -251,6 +252,6 @@ input_key_mouse(struct window_pane *wp, struct mouse_event *m) buf[len++] = x + 33; buf[len++] = y + 33; } - log_debug("writing mouse %.*s", (int)len, buf); + log_debug("writing mouse %.*s to %%%u", (int)len, buf, wp->id); bufferevent_write(wp->event, buf, len); } diff --git a/usr.bin/tmux/server-client.c b/usr.bin/tmux/server-client.c index 1cfd2a00d5c..67028ee10b7 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.159 2015/10/23 23:46:36 nicm Exp $ */ +/* $OpenBSD: server-client.c,v 1.160 2015/10/26 17:17:06 nicm Exp $ */ /* * Copyright (c) 2009 Nicholas Marriott @@ -369,6 +369,8 @@ server_client_check_mouse(struct client *c) wp = window_get_active_at(s->curw->window, x, y); if (wp != NULL) where = PANE; + log_debug("mouse at %u,%u is on pane %%%u", x, y, + wp->id); } if (where == NOWHERE) return (KEYC_NONE); -- 2.20.1