mirror of
https://github.com/meshtastic/Meshtastic-Android.git
synced 2026-04-20 22:23:37 +00:00
feat: add new configs
This commit is contained in:
parent
ca0ee58be2
commit
c6ad5dcfdf
2 changed files with 40 additions and 0 deletions
|
|
@ -199,6 +199,16 @@ fun ExternalNotificationConfigItemList(
|
|||
)
|
||||
}
|
||||
|
||||
item {
|
||||
SwitchPreference(title = "Use I2S as buzzer",
|
||||
checked = externalNotificationInput.useI2SAsBuzzer,
|
||||
enabled = enabled,
|
||||
onCheckedChange = {
|
||||
externalNotificationInput = externalNotificationInput.copy { useI2SAsBuzzer = it }
|
||||
})
|
||||
}
|
||||
item { Divider() }
|
||||
|
||||
item {
|
||||
PreferenceFooter(
|
||||
enabled = externalNotificationInput != extNotificationConfig || ringtoneInput != ringtone,
|
||||
|
|
|
|||
|
|
@ -103,6 +103,36 @@ fun TelemetryConfigItemList(
|
|||
})
|
||||
}
|
||||
|
||||
item {
|
||||
SwitchPreference(title = "Power metrics module enabled",
|
||||
checked = telemetryInput.powerMeasurementEnabled,
|
||||
enabled = enabled,
|
||||
onCheckedChange = {
|
||||
telemetryInput = telemetryInput.copy { powerMeasurementEnabled = it }
|
||||
})
|
||||
}
|
||||
item { Divider() }
|
||||
|
||||
item {
|
||||
EditTextPreference(title = "Power metrics update interval (seconds)",
|
||||
value = telemetryInput.powerUpdateInterval,
|
||||
enabled = enabled,
|
||||
keyboardActions = KeyboardActions(onDone = { focusManager.clearFocus() }),
|
||||
onValueChanged = {
|
||||
telemetryInput = telemetryInput.copy { powerUpdateInterval = it }
|
||||
})
|
||||
}
|
||||
|
||||
item {
|
||||
SwitchPreference(title = "Power metrics on-screen enabled",
|
||||
checked = telemetryInput.powerScreenEnabled,
|
||||
enabled = enabled,
|
||||
onCheckedChange = {
|
||||
telemetryInput = telemetryInput.copy { powerScreenEnabled = it }
|
||||
})
|
||||
}
|
||||
item { Divider() }
|
||||
|
||||
item {
|
||||
PreferenceFooter(
|
||||
enabled = telemetryInput != telemetryConfig,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue