summaryrefslogtreecommitdiff
path: root/kvmd/plugins/hid
diff options
context:
space:
mode:
Diffstat (limited to 'kvmd/plugins/hid')
-rw-r--r--kvmd/plugins/hid/otg/__init__.py8
-rw-r--r--kvmd/plugins/hid/otg/device.py4
-rw-r--r--kvmd/plugins/hid/serial.py6
3 files changed, 9 insertions, 9 deletions
diff --git a/kvmd/plugins/hid/otg/__init__.py b/kvmd/plugins/hid/otg/__init__.py
index 575190e5..b9c2c5b8 100644
--- a/kvmd/plugins/hid/otg/__init__.py
+++ b/kvmd/plugins/hid/otg/__init__.py
@@ -51,10 +51,10 @@ class Plugin(BaseHid):
noop: bool,
) -> None:
- self.__state_notifier = aiomulti.AioProcessNotifier()
+ self.__notifier = aiomulti.AioProcessNotifier()
- self.__keyboard_proc = KeyboardProcess(noop=noop, state_notifier=self.__state_notifier, **keyboard)
- self.__mouse_proc = MouseProcess(noop=noop, state_notifier=self.__state_notifier, **mouse)
+ self.__keyboard_proc = KeyboardProcess(noop=noop, notifier=self.__notifier, **keyboard)
+ self.__mouse_proc = MouseProcess(noop=noop, notifier=self.__notifier, **mouse)
@classmethod
def get_plugin_options(cls) -> Dict:
@@ -101,7 +101,7 @@ class Plugin(BaseHid):
if state != prev_state:
yield state
prev_state = state
- await self.__state_notifier.wait()
+ await self.__notifier.wait()
async def reset(self) -> None:
self.__keyboard_proc.send_reset_event()
diff --git a/kvmd/plugins/hid/otg/device.py b/kvmd/plugins/hid/otg/device.py
index 45681aba..b777dd56 100644
--- a/kvmd/plugins/hid/otg/device.py
+++ b/kvmd/plugins/hid/otg/device.py
@@ -47,7 +47,7 @@ class BaseDeviceProcess(multiprocessing.Process): # pylint: disable=too-many-in
name: str,
read_size: int,
initial_state: Dict,
- state_notifier: aiomulti.AioProcessNotifier,
+ notifier: aiomulti.AioProcessNotifier,
device_path: str,
select_timeout: float,
@@ -69,7 +69,7 @@ class BaseDeviceProcess(multiprocessing.Process): # pylint: disable=too-many-in
self.__fd = -1
self.__events_queue: multiprocessing.queues.Queue = multiprocessing.Queue()
- self.__state_flags = aiomulti.AioSharedFlags({"online": True, **initial_state}, state_notifier)
+ self.__state_flags = aiomulti.AioSharedFlags({"online": True, **initial_state}, notifier)
self.__stop_event = multiprocessing.Event()
def run(self) -> None:
diff --git a/kvmd/plugins/hid/serial.py b/kvmd/plugins/hid/serial.py
index 5abab1f5..bb97aec4 100644
--- a/kvmd/plugins/hid/serial.py
+++ b/kvmd/plugins/hid/serial.py
@@ -191,13 +191,13 @@ class Plugin(BaseHid, multiprocessing.Process): # pylint: disable=too-many-inst
self.__events_queue: multiprocessing.queues.Queue = multiprocessing.Queue()
- self.__state_notifier = aiomulti.AioProcessNotifier()
+ self.__notifier = aiomulti.AioProcessNotifier()
self.__state_flags = aiomulti.AioSharedFlags({
"online": True,
"caps": False,
"scroll": False,
"num": False,
- }, self.__state_notifier)
+ }, self.__notifier)
self.__stop_event = multiprocessing.Event()
@@ -243,7 +243,7 @@ class Plugin(BaseHid, multiprocessing.Process): # pylint: disable=too-many-inst
if state != prev_state:
yield state
prev_state = state
- await self.__state_notifier.wait()
+ await self.__notifier.wait()
@aiotools.atomic
async def reset(self) -> None: