mirror of
https://github.com/eried/portapack-mayhem.git
synced 2025-05-15 05:02:13 -04:00
Make better use of range_t methods.
This commit is contained in:
parent
ca3b1a2c5a
commit
7519b83379
8 changed files with 39 additions and 72 deletions
|
@ -118,13 +118,7 @@ void FrequencyField::on_focus() {
|
|||
}
|
||||
|
||||
rf::Frequency FrequencyField::clamp_value(rf::Frequency value) {
|
||||
if( value > range.max ) {
|
||||
value = range.max;
|
||||
}
|
||||
if( value < range.min ) {
|
||||
value = range.min;
|
||||
}
|
||||
return value;
|
||||
return range.clip(value);
|
||||
}
|
||||
|
||||
/* FrequencyKeypadView ***************************************************/
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue