From 8e28dbcc2d7eecafcb8f04b2b2312467977b87a3 Mon Sep 17 00:00:00 2001 From: James Rich <2199651+jamesarich@users.noreply.github.com> Date: Tue, 7 Oct 2025 20:50:34 -0500 Subject: [PATCH] feat(ui): Simplify connection status message (#3389) Signed-off-by: James Rich <2199651+jamesarich@users.noreply.github.com> --- .../geeksville/mesh/ui/connections/ConnectionsScreen.kt | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/app/src/main/java/com/geeksville/mesh/ui/connections/ConnectionsScreen.kt b/app/src/main/java/com/geeksville/mesh/ui/connections/ConnectionsScreen.kt index 0a6c746e0..3206b3325 100644 --- a/app/src/main/java/com/geeksville/mesh/ui/connections/ConnectionsScreen.kt +++ b/app/src/main/java/com/geeksville/mesh/ui/connections/ConnectionsScreen.kt @@ -104,7 +104,6 @@ fun ConnectionsScreen( connectionsViewModel.connectionState.collectAsStateWithLifecycle(ConnectionState.DISCONNECTED) val scanning by scanModel.spinner.collectAsStateWithLifecycle(false) val context = LocalContext.current - val info by connectionsViewModel.myNodeInfo.collectAsStateWithLifecycle() val ourNode by connectionsViewModel.ourNodeInfo.collectAsStateWithLifecycle() val selectedDevice by scanModel.selectedNotNullFlow.collectAsStateWithLifecycle() val bluetoothState by connectionsViewModel.bluetoothState.collectAsStateWithLifecycle() @@ -149,15 +148,12 @@ fun ConnectionsScreen( LaunchedEffect(connectionState, regionUnset) { when (connectionState) { ConnectionState.CONNECTED -> { - if (regionUnset) R.string.must_set_region else R.string.connected_to + if (regionUnset) R.string.must_set_region else R.string.connected } ConnectionState.DISCONNECTED -> R.string.not_connected ConnectionState.DEVICE_SLEEP -> R.string.connected_sleeping - }.let { - val firmwareString = info?.firmwareString ?: context.getString(R.string.unknown) - scanModel.setErrorText(context.getString(it, firmwareString)) - } + }.let { scanModel.setErrorText(context.getString(it)) } } Scaffold(