From 5f84cce7355ab5c8f0d8988b279cb3ad562a6198 Mon Sep 17 00:00:00 2001 From: Kentaro Fukuchi Date: Wed, 17 Jan 2024 23:09:02 +0900 Subject: [PATCH] Correctly disables the XRecord context. (probably) --- lib/pynput/_util/xorg.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/pynput/_util/xorg.py b/lib/pynput/_util/xorg.py index a777a499..b10a8810 100644 --- a/lib/pynput/_util/xorg.py +++ b/lib/pynput/_util/xorg.py @@ -425,7 +425,8 @@ def _stop_platform(self): self.wait() # Do this asynchronously to avoid deadlocks - self._display_record.record_disable_context(self._context) + self._display_stop.record_disable_context(self._context) + self._display_stop.flush() def _suppress_start(self, display): """Starts suppressing events.