refactor: convert connectionState to StateFlow

This commit is contained in:
andrekir 2024-11-12 09:08:08 -03:00
parent a980441fd1
commit cfdb245da2
8 changed files with 25 additions and 42 deletions

View file

@ -140,6 +140,7 @@ class MeshService : Service(), Logging {
DEVICE_SLEEP, // device is in LS sleep state, it will reconnected to us over bluetooth once it has data
;
fun isConnected() = this == CONNECTED
fun isDisconnected() = this == DISCONNECTED
}