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

Unified Diff: media/base/mock_filters.h

Issue 11144036: Update Decryptor interface to support audio decoding. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: remove leftover unretained Created 8 years, 2 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/decryptor.h ('k') | media/base/mock_filters.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/base/mock_filters.h
diff --git a/media/base/mock_filters.h b/media/base/mock_filters.h
index d5541a790f16d452aeea3af85c6b57d046bc31f4..518a180ee9301490b882f8b877cbfbfde6bd47ee 100644
--- a/media/base/mock_filters.h
+++ b/media/base/mock_filters.h
@@ -207,22 +207,33 @@ class MockDecryptor : public Decryptor {
const std::string& session_id));
MOCK_METHOD2(CancelKeyRequest, void(const std::string& key_system,
const std::string& session_id));
- MOCK_METHOD2(Decrypt, void(const scoped_refptr<DecoderBuffer>& encrypted,
+ MOCK_METHOD3(Decrypt, void(StreamType stream_type,
+ const scoped_refptr<DecoderBuffer>& encrypted,
const DecryptCB& decrypt_cb));
- MOCK_METHOD0(CancelDecrypt, void());
- // TODO(xhwang): This is a workaround of the issue that move-only parameters
- // are not supported in mocked methods. Remove this when the issue is fixed
- // (http://code.google.com/p/googletest/issues/detail?id=395).
+ MOCK_METHOD1(CancelDecrypt, void(StreamType stream_type));
+ // TODO(xhwang): The following two methods are workarounds of the issue that
+ // move-only parameters are not supported in mocked methods. Remove when the
+ // issue is fixed: http://code.google.com/p/googletest/issues/detail?id=395
+ MOCK_METHOD3(InitializeAudioDecoderMock,
+ void(const AudioDecoderConfig& config,
+ const DecoderInitCB& init_cb,
+ const KeyAddedCB& key_added_cb));
MOCK_METHOD3(InitializeVideoDecoderMock,
void(const VideoDecoderConfig& config,
const DecoderInitCB& init_cb,
const KeyAddedCB& key_added_cb));
+ MOCK_METHOD2(DecryptAndDecodeAudio,
+ void(const scoped_refptr<media::DecoderBuffer>& encrypted,
+ const AudioDecodeCB& audio_decode_cb));
MOCK_METHOD2(DecryptAndDecodeVideo,
void(const scoped_refptr<media::DecoderBuffer>& encrypted,
const VideoDecodeCB& video_decode_cb));
- MOCK_METHOD0(CancelDecryptAndDecodeVideo, void());
- MOCK_METHOD0(StopVideoDecoder, void());
+ MOCK_METHOD1(ResetDecoder, void(StreamType stream_type));
+ MOCK_METHOD1(DeinitializeDecoder, void(StreamType stream_type));
+ virtual void InitializeAudioDecoder(scoped_ptr<AudioDecoderConfig> config,
+ const DecoderInitCB& init_cb,
+ const KeyAddedCB& key_added_cb) OVERRIDE;
virtual void InitializeVideoDecoder(scoped_ptr<VideoDecoderConfig> config,
const DecoderInitCB& init_cb,
const KeyAddedCB& key_added_cb) OVERRIDE;
« no previous file with comments | « media/base/decryptor.h ('k') | media/base/mock_filters.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698