kopia lustrzana https://github.com/meshtastic/Meshtastic-Android
style: fix name and formatting
rodzic
145988ad75
commit
8d5cca93f1
|
@ -79,7 +79,7 @@ import com.google.accompanist.themeadapter.appcompat.AppCompatTheme
|
||||||
import dagger.hilt.android.AndroidEntryPoint
|
import dagger.hilt.android.AndroidEntryPoint
|
||||||
|
|
||||||
@AndroidEntryPoint
|
@AndroidEntryPoint
|
||||||
class DeviceSettingsFragment(val node: NodeInfo) : ScreenFragment("Device Settings"), Logging {
|
class DeviceSettingsFragment(val node: NodeInfo) : ScreenFragment("Radio Configuration"), Logging {
|
||||||
|
|
||||||
private val model: UIViewModel by activityViewModels()
|
private val model: UIViewModel by activityViewModels()
|
||||||
|
|
||||||
|
@ -163,18 +163,16 @@ fun RadioConfigNavHost(node: NodeInfo, viewModel: UIViewModel = viewModel()) {
|
||||||
isWaiting = false
|
isWaiting = false
|
||||||
val response = parsed.getConfigResponse
|
val response = parsed.getConfigResponse
|
||||||
radioConfig = response
|
radioConfig = response
|
||||||
enumValues<ConfigDest>().find { it.name == "${response.payloadVariantCase}" }?.let {
|
enumValues<ConfigDest>().find { it.name == "${response.payloadVariantCase}" }
|
||||||
navController.navigate(it.route)
|
?.let { navController.navigate(it.route) }
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
AdminProtos.AdminMessage.PayloadVariantCase.GET_MODULE_CONFIG_RESPONSE -> {
|
AdminProtos.AdminMessage.PayloadVariantCase.GET_MODULE_CONFIG_RESPONSE -> {
|
||||||
isWaiting = false
|
isWaiting = false
|
||||||
val response = parsed.getModuleConfigResponse
|
val response = parsed.getModuleConfigResponse
|
||||||
moduleConfig = response
|
moduleConfig = response
|
||||||
enumValues<ModuleDest>().find { it.name == "${response.payloadVariantCase}" }?.let {
|
enumValues<ModuleDest>().find { it.name == "${response.payloadVariantCase}" }
|
||||||
navController.navigate(it.route)
|
?.let { navController.navigate(it.route) }
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
AdminProtos.AdminMessage.PayloadVariantCase.GET_CANNED_MESSAGE_MODULE_MESSAGES_RESPONSE -> {
|
AdminProtos.AdminMessage.PayloadVariantCase.GET_CANNED_MESSAGE_MODULE_MESSAGES_RESPONSE -> {
|
||||||
|
@ -186,6 +184,7 @@ fun RadioConfigNavHost(node: NodeInfo, viewModel: UIViewModel = viewModel()) {
|
||||||
ringtone = parsed.getRingtoneResponse
|
ringtone = parsed.getRingtoneResponse
|
||||||
viewModel.getModuleConfig(destNum, ModuleConfigType.EXTNOTIF_CONFIG_VALUE)
|
viewModel.getModuleConfig(destNum, ModuleConfigType.EXTNOTIF_CONFIG_VALUE)
|
||||||
}
|
}
|
||||||
|
|
||||||
else -> TODO()
|
else -> TODO()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Ładowanie…
Reference in New Issue