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

Unified Diff: media/filters/ffmpeg_audio_decoder.h

Issue 10855051: Use enum instead of string in MessageLoopFactory::GetMessageLoop* (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 8 years, 4 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 | « media/base/pipeline_unittest.cc ('k') | media/filters/ffmpeg_audio_decoder.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/filters/ffmpeg_audio_decoder.h
diff --git a/media/filters/ffmpeg_audio_decoder.h b/media/filters/ffmpeg_audio_decoder.h
index c63edaed5ef76a1bccb8cf14a67cdd512bad893f..8e67f59c72c2dff6aec55b82d50f68f6d6517110 100644
--- a/media/filters/ffmpeg_audio_decoder.h
+++ b/media/filters/ffmpeg_audio_decoder.h
@@ -8,13 +8,16 @@
#include <list>
#include "base/callback.h"
-#include "base/message_loop.h"
#include "media/base/audio_decoder.h"
#include "media/base/demuxer_stream.h"
struct AVCodecContext;
struct AVFrame;
+namespace base {
+class MessageLoopProxy;
+}
+
namespace media {
class DataBuffer;
@@ -22,7 +25,10 @@ class DecoderBuffer;
class MEDIA_EXPORT FFmpegAudioDecoder : public AudioDecoder {
public:
- FFmpegAudioDecoder(const base::Callback<MessageLoop*()>& message_loop_cb);
+ typedef base::Callback<
+ scoped_refptr<base::MessageLoopProxy>()> MessageLoopFactoryCB;
+ explicit FFmpegAudioDecoder(
+ const MessageLoopFactoryCB& message_loop_factory_cb);
// AudioDecoder implementation.
virtual void Initialize(const scoped_refptr<DemuxerStream>& stream,
@@ -58,8 +64,9 @@ class MEDIA_EXPORT FFmpegAudioDecoder : public AudioDecoder {
base::TimeDelta GetNextOutputTimestamp() const;
// This is !is_null() iff Initialize() hasn't been called.
- base::Callback<MessageLoop*()> message_loop_factory_cb_;
- MessageLoop* message_loop_;
+ MessageLoopFactoryCB message_loop_factory_cb_;
+
+ scoped_refptr<base::MessageLoopProxy> message_loop_;
scoped_refptr<DemuxerStream> demuxer_stream_;
StatisticsCB statistics_cb_;
« no previous file with comments | « media/base/pipeline_unittest.cc ('k') | media/filters/ffmpeg_audio_decoder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698