diff options
Diffstat (limited to 'menus.c')
-rw-r--r-- | menus.c | 18 |
1 files changed, 9 insertions, 9 deletions
@@ -2278,15 +2278,15 @@ static int Submenu_Mult_Value(float mult_by) break; case Show_offset: - if (fabs(new_value)<globals.Flash.ampl_zero_equiv[channel] && mult_by>1.0) { - if (new_value<0.0 || globals.Flash.max_offset[channel]<globals.Flash.ampl_zero_equiv[channel]) { - new_value=-globals.Flash.ampl_zero_equiv[channel]; + if (fabs(new_value)<globals.Flash.os_zero_equiv[channel] && mult_by>1.0) { + if (new_value<0.0 || globals.Flash.max_offset[channel]<globals.Flash.os_zero_equiv[channel]) { + new_value=-globals.Flash.os_zero_equiv[channel]; } else { - new_value=globals.Flash.ampl_zero_equiv[channel]; + new_value=globals.Flash.os_zero_equiv[channel]; } } - if (fabs(new_value) < globals.Flash.ampl_zero_equiv[channel]) { + if (fabs(new_value) < globals.Flash.os_zero_equiv[channel]) { if (new_value<0.0) { new_value=-smallest_allowed_number; } else { @@ -2496,9 +2496,9 @@ static void Submenu_Service_Encoder(int encoder_change) } } - else if ((channel<max_channels) && abs_Submenu_Value<globals.Flash.ampl_zero_equiv[channel] && (Submenu_Numeric_Parameter-channel)==Show_offset) { - abs_Submenu_Value=globals.Flash.ampl_zero_equiv[channel]; - if (globals.Flash.max_offset[channel]<globals.Flash.ampl_zero_equiv[channel]) { + else if ((channel<max_channels) && abs_Submenu_Value<globals.Flash.os_zero_equiv[channel] && (Submenu_Numeric_Parameter-channel)==Show_offset) { + abs_Submenu_Value=globals.Flash.os_zero_equiv[channel]; + if (globals.Flash.max_offset[channel]<globals.Flash.os_zero_equiv[channel]) { Submenu_Value=-abs_Submenu_Value; } } @@ -2730,7 +2730,7 @@ static void Submenu_Service_Encoder(int encoder_change) if (globals.Flash.min_offset[channel]==globals.Flash.max_offset[channel]) { return; } - if (fabs(new_value) < globals.Flash.ampl_zero_equiv[channel]) { + if (fabs(new_value) < globals.Flash.os_zero_equiv[channel]) { if (Submenu_Value<0.0) { new_value=-smallest_allowed_number; } else { |