From 34a6c4748c25ef83cc4c2ff5aab9bda62e2814e1 Mon Sep 17 00:00:00 2001 From: Nicolas Pennequin Date: Mon, 23 Jul 2007 17:11:13 +0000 Subject: [PATCH] Fix FS#7441: Volume wasn't mapped correctly to the enum cases when using the %?pv WPS tag. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@13967 a1c6a512-1295-4272-9138-f99709370657 --- apps/gui/gwps-common.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/apps/gui/gwps-common.c b/apps/gui/gwps-common.c index 91f60d7d14..e5f0e882e8 100644 --- a/apps/gui/gwps-common.c +++ b/apps/gui/gwps-common.c @@ -842,9 +842,8 @@ static char *get_token_value(struct gui_wps *gwps, else { *intval = (limit - 3) * (global_settings.volume - - sound_min(SOUND_VOLUME)) - / (sound_max(SOUND_VOLUME) - - sound_min(SOUND_VOLUME)) + 2; + - sound_min(SOUND_VOLUME) - 1) + / (-1 - sound_min(SOUND_VOLUME)) + 2; } } return buf;