diff options
author | 2009-08-08 10:39:29 +0200 | |
---|---|---|
committer | 2009-08-08 10:39:29 +0200 | |
commit | c2dbadc6ec891f9bf0287698eab18dccc7f1b52d (patch) | |
tree | f727724a672e76fca807cbcb19964f3e94ab8c19 /callbacks.c | |
parent | ce429b6a60046d8fd75fcb3973a63a4b284c96f8 (diff) |
added duration calc to GME and FLAC
Diffstat (limited to 'callbacks.c')
-rw-r--r-- | callbacks.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/callbacks.c b/callbacks.c index 4d86b537..6fde02a4 100644 --- a/callbacks.c +++ b/callbacks.c @@ -49,10 +49,10 @@ on_playpos_value_changed (GtkRange *range, return; } if (playlist_current.codec) { - if (playlist_current.codec->info.duration > 0) { + if (playlist_current.duration > 0) { int val = gtk_range_get_value (range); int upper = gtk_adjustment_get_upper (gtk_range_get_adjustment (range)); - float time = playlist_current.codec->info.duration / (float)upper * (float)val; + float time = playlist_current.duration / (float)upper * (float)val; messagepump_push (M_SONGSEEK, 0, (int)time * 1000, 0); } } |