From bfcd32465b4774e7bc7d5566af0602b093fe093a Mon Sep 17 00:00:00 2001 From: chrys Date: Sat, 24 Sep 2016 23:05:28 +0200 Subject: [PATCH] improve set/clear window mode commands --- config/keyboard/test.conf | 2 +- .../commands/commands/clear_window_application.py | 1 + src/fenrir-package/commands/commands/set_window_application.py | 1 + 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/config/keyboard/test.conf b/config/keyboard/test.conf index c961fe3f..2a2bb147 100644 --- a/config/keyboard/test.conf +++ b/config/keyboard/test.conf @@ -23,7 +23,7 @@ KEY_FENRIR,KEY_KP8=curr_screen_before_cursor KEY_FENRIR,KEY_KP2=curr_screen_after_cursor KEY_FENRIR,KEY_1=set_window_application KEY_FENRIR,KEY_3=clear_window_application -KEY_FENRIR,KEY_3=clear_bookmark_1 +#KEY_FENRIR,KEY_3=clear_bookmark_1 #KEY_FENRIR,KEY_1=set_bookmark_1 KEY_FENRIR,KEY_2=bookmark_1 KEY_KPPLUS=last_incomming diff --git a/src/fenrir-package/commands/commands/clear_window_application.py b/src/fenrir-package/commands/commands/clear_window_application.py index 5d6b6c18..81d1707c 100644 --- a/src/fenrir-package/commands/commands/clear_window_application.py +++ b/src/fenrir-package/commands/commands/clear_window_application.py @@ -18,6 +18,7 @@ class command(): def run(self): if self.env['runtime']['cursorManager'].clearWindowForApplication(): + currApp = self.env['runtime']['applicationManager'].getCurrentApplication() self.env['runtime']['outputManager'].presentText('Window Mode off for application ' + currApp, interrupt=True) else: self.env['runtime']['outputManager'].presentText("Not in window Mode", interrupt=True) diff --git a/src/fenrir-package/commands/commands/set_window_application.py b/src/fenrir-package/commands/commands/set_window_application.py index aead0c7f..61940b31 100644 --- a/src/fenrir-package/commands/commands/set_window_application.py +++ b/src/fenrir-package/commands/commands/set_window_application.py @@ -18,6 +18,7 @@ class command(): def run(self): if self.env['runtime']['cursorManager'].setWindowForApplication(): + currApp = self.env['runtime']['applicationManager'].getCurrentApplication() self.env['runtime']['outputManager'].presentText('Window Mode on for application ' + currApp, interrupt=True) self.env['runtime']['cursorManager'].clearMarks() else: