summaryrefslogtreecommitdiff
path: root/apps/gui/skin_engine/skin_tokens.c
diff options
context:
space:
mode:
Diffstat (limited to 'apps/gui/skin_engine/skin_tokens.c')
-rw-r--r--apps/gui/skin_engine/skin_tokens.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/apps/gui/skin_engine/skin_tokens.c b/apps/gui/skin_engine/skin_tokens.c
index f455999b2a..1fbe3d714e 100644
--- a/apps/gui/skin_engine/skin_tokens.c
+++ b/apps/gui/skin_engine/skin_tokens.c
@@ -35,6 +35,7 @@
35#include "sound.h" 35#include "sound.h"
36#include "debug.h" 36#include "debug.h"
37#include "cuesheet.h" 37#include "cuesheet.h"
38#include "replaygain.h"
38#ifdef HAVE_LCD_CHARCELLS 39#ifdef HAVE_LCD_CHARCELLS
39#include "hwcompat.h" 40#include "hwcompat.h"
40#endif 41#endif
@@ -1305,8 +1306,8 @@ const char *get_token_value(struct gui_wps *gwps,
1305 { 1306 {
1306 int type; 1307 int type;
1307 if (LIKELY(id3)) 1308 if (LIKELY(id3))
1308 type = get_replaygain_mode(id3->track_gain_string != NULL, 1309 type = get_replaygain_mode(id3->track_gain != 0,
1309 id3->album_gain_string != NULL); 1310 id3->album_gain != 0);
1310 else 1311 else
1311 type = -1; 1312 type = -1;
1312 1313
@@ -1331,11 +1332,11 @@ const char *get_token_value(struct gui_wps *gwps,
1331 /* due to above, coming here with !id3 shouldn't be possible */ 1332 /* due to above, coming here with !id3 shouldn't be possible */
1332 case 2: 1333 case 2:
1333 case 4: 1334 case 4:
1334 strlcpy(buf, id3->track_gain_string, buf_size); 1335 replaygain_itoa(buf, buf_size, id3->track_gain);
1335 break; 1336 break;
1336 case 3: 1337 case 3:
1337 case 5: 1338 case 5:
1338 strlcpy(buf, id3->album_gain_string, buf_size); 1339 replaygain_itoa(buf, buf_size, id3->album_gain);
1339 break; 1340 break;
1340 } 1341 }
1341 return buf; 1342 return buf;