diff --git a/VERSION b/VERSION index fbcbf73..8cf6caf 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -3.4.0 \ No newline at end of file +3.4.1 \ No newline at end of file diff --git a/stubs/pythonista_stubs/cb.pyi b/stubs/pythonista_stubs/cb.pyi index 7b40215..2fbffa9 100644 --- a/stubs/pythonista_stubs/cb.pyi +++ b/stubs/pythonista_stubs/cb.pyi @@ -4,7 +4,7 @@ according to [pythonista.cb docs](https://omz-software.com/pythonista/docs/ios/c from typing import Protocol -from _cb import ( # type: ignore[import-not-found] +from _cb import ( CH_PROP_AUTHENTICATED_SIGNED_WRITES, CH_PROP_BROADCAST, CH_PROP_EXTENDED_PROPERTIES, @@ -48,6 +48,7 @@ __all__ = ( "Characteristic", "Peripheral", "Service", + "SharedCentralManager", "cancel_peripheral_connection", "connect_peripheral", "get_state", @@ -55,6 +56,7 @@ __all__ = ( "scan_for_peripherals", "set_central_delegate", "set_verbose", + "shared_manager", "stop_scan", ) @@ -81,6 +83,14 @@ class _CentralManagerDelegate(Protocol): def did_update_value(self, c: Characteristic, error: str | None) -> None: ... def did_update_state(self) -> None: ... +# Documented at https://github.com/hbmartin/pythonista-stubs/pull/11#issuecomment-3180673698 +class SharedCentralManager(CentralManager): + delegate: _CentralManagerDelegate | None + verbose: bool = False + def verbose_log(self) -> None: ... + +shared_manager: SharedCentralManager | None = None + def set_central_delegate(delegate: _CentralManagerDelegate) -> None: ... def set_verbose(flag: bool) -> None: ... def scan_for_peripherals() -> None: ...