mirror of
https://github.com/portapack-mayhem/mayhem-firmware.git
synced 2025-08-14 15:37:43 +00:00
ui::OptionsField match option value by ==, not >=.
I think I used >= to match baseband filter bandwidth, but then the options would all have to be in increasing order to do the right thing, which is not what another developer would expect!
This commit is contained in:
@@ -397,7 +397,7 @@ void OptionsField::set_selected_index(const size_t new_index) {
|
||||
void OptionsField::set_by_value(value_t v) {
|
||||
size_t new_index { 0 };
|
||||
for(const auto& option : options) {
|
||||
if( option.second >= v ) {
|
||||
if( option.second == v ) {
|
||||
set_selected_index(new_index);
|
||||
break;
|
||||
}
|
||||
|
Reference in New Issue
Block a user