aboutsummaryrefslogtreecommitdiffstats
path: root/src/decoder/DecoderControl.cxx
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2014-08-27 18:38:41 +0200
committerMax Kellermann <max@duempel.org>2014-08-27 18:48:43 +0200
commitba6ba7d4be6f43c5b6ba65a106fbf2ed40a53b45 (patch)
treeb5da178e2de8694c6354794631d3bc3906368442 /src/decoder/DecoderControl.cxx
parent58e6f660f3ff0abc77eb879814188809e9bf1995 (diff)
downloadmpd-ba6ba7d4be6f43c5b6ba65a106fbf2ed40a53b45.tar.gz
mpd-ba6ba7d4be6f43c5b6ba65a106fbf2ed40a53b45.tar.xz
mpd-ba6ba7d4be6f43c5b6ba65a106fbf2ed40a53b45.zip
DecoderControl: use std::chrono::duration for Seek()
Diffstat (limited to 'src/decoder/DecoderControl.cxx')
-rw-r--r--src/decoder/DecoderControl.cxx5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/decoder/DecoderControl.cxx b/src/decoder/DecoderControl.cxx
index d78fc66c9..c4892a659 100644
--- a/src/decoder/DecoderControl.cxx
+++ b/src/decoder/DecoderControl.cxx
@@ -105,16 +105,15 @@ DecoderControl::Stop()
}
bool
-DecoderControl::Seek(double where)
+DecoderControl::Seek(SongTime t)
{
assert(state != DecoderState::START);
- assert(where >= 0.0);
if (state == DecoderState::STOP ||
state == DecoderState::ERROR || !seekable)
return false;
- seek_where = where;
+ seek_time = t;
seek_error = false;
LockSynchronousCommand(DecoderCommand::SEEK);