From 0cfa7bd2a8741fbd530c7492655861f9f55227b4 Mon Sep 17 00:00:00 2001 From: Gustavo Zambonin Date: Fri, 16 Oct 2015 15:46:15 -0300 Subject: [PATCH] page.py: quit without prompt restored docs.py: reflect change on docs --- rtv/docs.py | 2 +- rtv/page.py | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/rtv/docs.py b/rtv/docs.py index 6d09d90..0e9b7f1 100644 --- a/rtv/docs.py +++ b/rtv/docs.py @@ -29,7 +29,7 @@ Basic Commands `r` or `F5` : Refresh page content `u` : Log in or switch accounts `?` : Show the help screen - `q` : Quit + `q/Q` : Quit/Force quit Authenticated Commands `a/z` : Upvote/downvote diff --git a/rtv/page.py b/rtv/page.py index 0219164..0c9b8d7 100644 --- a/rtv/page.py +++ b/rtv/page.py @@ -275,6 +275,10 @@ class BasePage(object): elif ch != 'n': curses.flash() + @BaseController.register('Q') + def force_exit(self): + sys.exit() + @BaseController.register('?') def help(self): show_help(self._content_window)