mirror of
https://github.com/mofeng-git/One-KVM.git
synced 2025-12-13 01:30:31 +08:00
fb_requested on lock
This commit is contained in:
parent
6a5e3e47bb
commit
775f8741a0
@ -77,8 +77,6 @@ class RfbClient(RfbClientStream): # pylint: disable=too-many-instance-attribute
|
|||||||
self.__rfb_version = 0
|
self.__rfb_version = 0
|
||||||
self._encodings = RfbClientEncodings(frozenset())
|
self._encodings = RfbClientEncodings(frozenset())
|
||||||
|
|
||||||
self._lock = asyncio.Lock()
|
|
||||||
|
|
||||||
get_logger(0).info("Connected client: %s", self._remote)
|
get_logger(0).info("Connected client: %s", self._remote)
|
||||||
|
|
||||||
# =====
|
# =====
|
||||||
|
|||||||
@ -108,6 +108,8 @@ class _Client(RfbClient): # pylint: disable=too-many-instance-attributes
|
|||||||
self.__mouse_buttons: Dict[str, Optional[bool]] = {"left": None, "right": None, "middle": None}
|
self.__mouse_buttons: Dict[str, Optional[bool]] = {"left": None, "right": None, "middle": None}
|
||||||
self.__mouse_move = {"x": -1, "y": -1}
|
self.__mouse_move = {"x": -1, "y": -1}
|
||||||
|
|
||||||
|
self._lock = asyncio.Lock()
|
||||||
|
|
||||||
# =====
|
# =====
|
||||||
|
|
||||||
async def run(self) -> None:
|
async def run(self) -> None:
|
||||||
@ -277,6 +279,7 @@ class _Client(RfbClient): # pylint: disable=too-many-instance-attributes
|
|||||||
await self.__kvmd.set_streamer_params(user, passwd, self._encodings.tight_jpeg_quality, self.__desired_fps)
|
await self.__kvmd.set_streamer_params(user, passwd, self._encodings.tight_jpeg_quality, self.__desired_fps)
|
||||||
|
|
||||||
async def _on_fb_update_request(self) -> None:
|
async def _on_fb_update_request(self) -> None:
|
||||||
|
async with self._lock:
|
||||||
self.__fb_requested = True
|
self.__fb_requested = True
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user