From 845b8da451ec5a27ac267ff2301c2516f28449b7 Mon Sep 17 00:00:00 2001 From: Peter D'Hoye Date: Sun, 24 Jun 2007 00:17:28 +0000 Subject: Limit minimum db scale value when switching from linear to logaritmic peakmeter scale. Fixes FS #7325 git-svn-id: svn://svn.rockbox.org/rockbox/trunk@13696 a1c6a512-1295-4272-9138-f99709370657 --- apps/menus/display_menu.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'apps/menus') diff --git a/apps/menus/display_menu.c b/apps/menus/display_menu.c index 60b06d7f4f..5114feafb0 100644 --- a/apps/menus/display_menu.c +++ b/apps/menus/display_menu.c @@ -427,6 +427,10 @@ static int peak_meter_scale(void) { /* we only store -dBfs */ global_settings.peak_meter_min = -peak_meter_get_min() / 100; global_settings.peak_meter_max = -peak_meter_get_max() / 100; + + /* limit the returned value to the allowed range */ + if(global_settings.peak_meter_min > 89) + global_settings.peak_meter_min = 89; } else { int max; -- cgit v1.2.3