mirror of
https://github.com/aljazceru/Android-nRF-Toolbox.git
synced 2025-12-23 01:14:26 +01:00
Show disconnect option only when connected
This commit is contained in:
@@ -18,7 +18,7 @@ internal fun ProfileAppBar(
|
|||||||
openLogger: () -> Unit
|
openLogger: () -> Unit
|
||||||
) {
|
) {
|
||||||
if (deviceName?.isNotBlank() == true) {
|
if (deviceName?.isNotBlank() == true) {
|
||||||
if (connectionState !is ProfileUiState.Disconnected) {
|
if (connectionState is ProfileUiState.Connected) {
|
||||||
LoggerIconAppBar(deviceName, navigateUp, disconnect, openLogger)
|
LoggerIconAppBar(deviceName, navigateUp, disconnect, openLogger)
|
||||||
} else {
|
} else {
|
||||||
LoggerBackIconAppBar(deviceName, navigateUp) { openLogger() }
|
LoggerBackIconAppBar(deviceName, navigateUp) { openLogger() }
|
||||||
|
|||||||
Reference in New Issue
Block a user