Skip to content

Commit

Permalink
refactor: reorder modemPreset enum
Browse files Browse the repository at this point in the history
  • Loading branch information
andrekir committed Sep 8, 2023
1 parent 86cdb01 commit 33c16de
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions app/src/main/java/com/geeksville/mesh/model/ChannelOption.kt
Original file line number Diff line number Diff line change
Expand Up @@ -65,14 +65,15 @@ enum class ChannelOption(
val configRes: Int,
val bandwidth: Float,
) {
LONG_SLOW(ModemPreset.LONG_SLOW, R.string.modem_config_slow_long, .125f),
VERY_LONG_SLOW(ModemPreset.VERY_LONG_SLOW, R.string.modem_config_very_long, .0625f),
MEDIUM_SLOW(ModemPreset.MEDIUM_SLOW, R.string.modem_config_slow_medium, .250f),
MEDIUM_FAST(ModemPreset.MEDIUM_FAST, R.string.modem_config_medium, .250f),
SHORT_SLOW(ModemPreset.SHORT_SLOW, R.string.modem_config_slow_short, .250f),
SHORT_FAST(ModemPreset.SHORT_FAST, R.string.modem_config_short, .250f),
SHORT_SLOW(ModemPreset.SHORT_SLOW, R.string.modem_config_slow_short, .250f),
MEDIUM_FAST(ModemPreset.MEDIUM_FAST, R.string.modem_config_medium, .250f),
MEDIUM_SLOW(ModemPreset.MEDIUM_SLOW, R.string.modem_config_slow_medium, .250f),
LONG_FAST(ModemPreset.LONG_FAST, R.string.modem_config_long, .250f),
LONG_MODERATE(ModemPreset.LONG_MODERATE, R.string.modem_config_mod_long, .125f),
LONG_FAST(ModemPreset.LONG_FAST, R.string.modem_config_long, .250f);
LONG_SLOW(ModemPreset.LONG_SLOW, R.string.modem_config_slow_long, .125f),
VERY_LONG_SLOW(ModemPreset.VERY_LONG_SLOW, R.string.modem_config_very_long, .0625f),
;

companion object {
fun bandwidth(modemPreset: ModemPreset?): Float {
Expand Down

0 comments on commit 33c16de

Please sign in to comment.