summaryrefslogtreecommitdiff
path: root/kvmd/plugins/hid/ch9329/keyboard.py
diff options
context:
space:
mode:
authorMaxim Devaev <[email protected]>2023-06-01 17:07:40 +0300
committerMaxim Devaev <[email protected]>2023-07-10 03:02:28 +0300
commit2730b1184012f74968c90b35687b679a0a15b747 (patch)
treeb5ed19fdac91d13339c2d54c9c2f1158e40ee26a /kvmd/plugins/hid/ch9329/keyboard.py
parentce81c872eaf8422beae9e33ffce133957f26a797 (diff)
ch9329: using bytes instead of list[int]
Diffstat (limited to 'kvmd/plugins/hid/ch9329/keyboard.py')
-rw-r--r--kvmd/plugins/hid/ch9329/keyboard.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/kvmd/plugins/hid/ch9329/keyboard.py b/kvmd/plugins/hid/ch9329/keyboard.py
index 26eb7e6a..9aa16d9d 100644
--- a/kvmd/plugins/hid/ch9329/keyboard.py
+++ b/kvmd/plugins/hid/ch9329/keyboard.py
@@ -46,7 +46,7 @@ class Keyboard:
async def get_leds(self) -> dict[str, bool]:
return (await self.__leds.get())
- def process_key(self, key: str, state: bool) -> list[int]:
+ def process_key(self, key: str, state: bool) -> bytes:
code = KEYMAP[key].usb.code
is_modifier = KEYMAP[key].usb.is_modifier
if state:
@@ -65,4 +65,4 @@ class Keyboard:
]
for (index, code) in enumerate(self.__active_keys):
cmd[index + 5] = code
- return cmd
+ return bytes(cmd)