commit 67c22a1ac0fb7ef68a2af714df5a130e6afede92 Author: Damian Johnson atagar@torproject.org Date: Sun May 15 11:06:42 2016 -0700
Don't have 'up' move cursor to index zero
This is something Sambuddha had that I changed, but on reflection his behavior was better. When on the top row of the event dialog and press 'up' leave the cursor where it is (rather than move it to the first position). --- nyx/popups.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/nyx/popups.py b/nyx/popups.py index 9163166..3f04eed 100644 --- a/nyx/popups.py +++ b/nyx/popups.py @@ -477,8 +477,10 @@ def new_select_event_types(initial_selection): key = nyx.curses.key_input()
if key.match('up'): - if selection < 10: - selection = max(selection - 5, 0) + if selection < 5: + pass + elif selection < 10: + selection -= 5 elif selection < 13: selection = 5 elif selection < len(events) + 10:
tor-commits@lists.torproject.org