From 5190963f1baf22a313ed70a964c2a83174f4e841 Mon Sep 17 00:00:00 2001 From: Paul LeoNerd Evans Date: Thu, 6 Dec 2012 02:09:03 +0000 Subject: Make sure to implement newer event types in debug function --- termkey.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/termkey.c b/termkey.c index c3f8060..1ed92fc 100644 --- a/termkey.c +++ b/termkey.c @@ -141,6 +141,23 @@ static void print_key(TermKey *tk, TermKeyKey *key) fprintf(stderr, "Mouse ev=%d button=%d pos=(%d,%d)\n", ev, button, line, col); } break; + case TERMKEY_TYPE_POSITION: + { + int line, col; + termkey_interpret_position(tk, key, &line, &col); + fprintf(stderr, "Position report pos=(%d,%d)\n", line, col); + } + break; + case TERMKEY_TYPE_MODEREPORT: + { + int initial, mode, value; + termkey_interpret_modereport(tk, key, &initial, &mode, &value); + fprintf(stderr, "Mode report mode=%s %d val=%d\n", initial == '?' ? "DEC" : "ANSI", mode, value); + } + break; + case TERMKEY_TYPE_UNKNOWN_CSI: + fprintf(stderr, "unknown CSI\n"); + break; } int m = key->modifiers; -- cgit v1.2.3-70-g09d2