decoder/Client: add DecoderCommand/seek virtual methods

This commit is contained in:
Max Kellermann
2016-11-18 08:15:07 +01:00
parent 66fb352cca
commit 47a0f46ce8
24 changed files with 156 additions and 172 deletions

View File

@@ -373,7 +373,7 @@ sidplay_file_decode(DecoderClient &client, Path path_fs)
if (cmd == DecoderCommand::SEEK) {
unsigned data_time = player.time();
unsigned target_time =
decoder_seek_time(client).ToScale(timebase);
client.GetSeekTime().ToScale(timebase);
/* can't rewind so return to zero and seek forward */
if(target_time<data_time) {
@@ -386,7 +386,7 @@ sidplay_file_decode(DecoderClient &client, Path path_fs)
player.play(buffer, ARRAY_SIZE(buffer)) > 0)
data_time = player.time();
decoder_command_finished(client);
client.CommandFinished();
}
if (end > 0 && player.time() >= end)