summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/keyboard.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/keyboard.py b/src/keyboard.py
index 1344035f..b27ed5f5 100644
--- a/src/keyboard.py
+++ b/src/keyboard.py
@@ -28,7 +28,10 @@ def get_next_byte(s):
"""
Read the next byte of the utf-8 char
"""
- c = s.getkey()
+ try:
+ c = s.getkey()
+ except:
+ return "KEY_RESIZE"
if len(c) > 4:
return (None, c)
return (ord(c), c)