From 9f1ae40775e7688bb5098cb89464be31da994f3f Mon Sep 17 00:00:00 2001 From: Athanasius Date: Wed, 7 Apr 2021 17:51:45 +0100 Subject: [PATCH] hotkey: Make LinuxHotkeyMgr 'pass' implementations. We do need to 'implement' them, but it's a all a no-op on Linux. --- hotkey.py | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) diff --git a/hotkey.py b/hotkey.py index ff97ec4e..7b653f61 100644 --- a/hotkey.py +++ b/hotkey.py @@ -654,9 +654,27 @@ class WindowsHotkeyMgr(AbstractHotkeyMgr): class LinuxHotKeyMgr(AbstractHotkeyMgr): - """Hot key management.""" + """ + Hot key management. - pass + Not actually implemented on Linux. It's a no-op instead. + """ + + def register(self, root, keycode, modifiers) -> None: + """Register the hotkey handler.""" + pass + + def unregister(self) -> None: + """Unregister the hotkey handling.""" + pass + + def play_good(self) -> None: + """Play the 'good' sound.""" + pass + + def play_bad(self) -> None: + """Play the 'bad' sound.""" + pass def get_hotkeymgr(*args, **kwargs) -> AbstractHotkeyMgr: