Keystroke editor can execute the actions directly

This commit is contained in:
2015-08-21 09:51:01 -05:00
parent 71fed7300b
commit 7b840f29c4
3 changed files with 21 additions and 9 deletions

View File

@@ -128,7 +128,7 @@ class Controller(object):
pub.subscribe(self.manage_stream_errors, "streamError")
pub.subscribe(self.create_new_buffer, "create-new-buffer")
pub.subscribe(self.restart_streams, "restart-streams")
pub.subscribe(self.execute_action, "execute-action")
if system == "Windows":
pub.subscribe(self.invisible_shorcuts_changed, "invisible-shorcuts-changed")
widgetUtils.connect_event(self.view, widgetUtils.MENU, self.show_hide, menuitem=self.view.show_hide)
@@ -1344,5 +1344,9 @@ class Controller(object):
def repeat_item(self, *args, **kwargs):
output.speak(self.get_current_buffer().get_message())
def execute_action(self, action):
if hasattr(self, action):
getattr(self, action)()
def __del__(self):
config.app.write()