summaryrefslogtreecommitdiffstats
path: root/media/base/pipeline_impl.cc
diff options
context:
space:
mode:
Diffstat (limited to 'media/base/pipeline_impl.cc')
-rw-r--r--media/base/pipeline_impl.cc9
1 files changed, 9 insertions, 0 deletions
diff --git a/media/base/pipeline_impl.cc b/media/base/pipeline_impl.cc
index 88c3537..49ffb98 100644
--- a/media/base/pipeline_impl.cc
+++ b/media/base/pipeline_impl.cc
@@ -488,6 +488,15 @@ void PipelineThread::SeekTask(base::TimeDelta time,
++iter) {
(*iter)->media_filter()->Seek(time);
}
+
+ // TODO(hclam): we should set the time when the above seek operations were all
+ // successful and first frame/packet at the desired time is decoded. I'm
+ // setting the time here because once we do the callback the user can ask for
+ // current time immediately, which is the old time. In order to get rid this
+ // little glitch, we either assume the seek was successful and time is updated
+ // immediately here or we set time and do callback when we have new
+ // frames/packets.
+ SetTime(time);
if (seek_callback) {
seek_callback->Run(true);
delete seek_callback;