From 521c329db911801eb858258426deb8194a149551 Mon Sep 17 00:00:00 2001 From: Ivan Habunek Date: Fri, 5 Jan 2018 17:43:44 +0100 Subject: [PATCH] Hacky way to support up/down arrows They actually return 3 chars instead of 1, not sure why, but the third one resolves to "A" for up and "B" for down, so good enough for now. fixes #30 --- toot/app.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/toot/app.py b/toot/app.py index 75c3a7c..d644d9e 100644 --- a/toot/app.py +++ b/toot/app.py @@ -80,10 +80,10 @@ class TimelineApp: if status: webbrowser.open(status['url']) - elif key.lower() == 'j' or key == curses.KEY_DOWN: + elif key.lower() == 'j' or key == 'B': self.select_next() - elif key.lower() == 'k' or key == curses.KEY_UP: + elif key.lower() == 'k' or key == 'A': self.select_previous() elif key == 'KEY_RESIZE':