Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(11357)

Unified Diff: content/renderer/media/ipc_video_decoder.cc

Issue 6969026: Convert Filter::Seek() to use new callback system. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: More CR fixes Created 9 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/renderer/media/ipc_video_decoder.h ('k') | media/base/composite_filter.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/media/ipc_video_decoder.cc
diff --git a/content/renderer/media/ipc_video_decoder.cc b/content/renderer/media/ipc_video_decoder.cc
index 37f7983c2566dbf3a5b9b4d9978bdc42cb6e6f49..6c477a3eb2f6c5fbc9af165afd9e21bd9904f740 100644
--- a/content/renderer/media/ipc_video_decoder.cc
+++ b/content/renderer/media/ipc_video_decoder.cc
@@ -102,8 +102,8 @@ void IpcVideoDecoder::Flush(media::FilterCallback* callback) {
}
void IpcVideoDecoder::Seek(base::TimeDelta time,
- media::FilterCallback* callback) {
- seek_callback_.reset(callback);
+ const media::FilterStatusCB& cb) {
+ seek_cb_ = cb;
decode_engine_->Seek();
}
@@ -155,8 +155,7 @@ void IpcVideoDecoder::OnFlushComplete() {
void IpcVideoDecoder::OnSeekComplete() {
DCHECK_EQ(ChildProcess::current()->io_message_loop(), MessageLoop::current());
- seek_callback_->Run();
- seek_callback_.reset();
+ ResetAndRunCB(&seek_cb_, media::PIPELINE_OK);
}
void IpcVideoDecoder::OnError() {
« no previous file with comments | « content/renderer/media/ipc_video_decoder.h ('k') | media/base/composite_filter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698