mirror of
https://github.com/eried/portapack-mayhem.git
synced 2024-12-25 07:19:28 -05: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:
parent
2a2e65abad
commit
42d13e6713
@ -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;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user