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

Unified Diff: media/base/mock_filters.h

Issue 1423163004: media: Replace DecryptorReadyCB with CdmReadyCB. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix android Created 5 years, 1 month 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
Index: media/base/mock_filters.h
diff --git a/media/base/mock_filters.h b/media/base/mock_filters.h
index dffbab06f3b5c7db10983bb05fb1ffbfe82b2d9f..5fb2a3e9e6c60775772fef061f6023682f1e1ad6 100644
--- a/media/base/mock_filters.h
+++ b/media/base/mock_filters.h
@@ -8,9 +8,11 @@
#include <string>
#include "base/callback.h"
+#include "base/macros.h"
#include "media/base/audio_decoder.h"
#include "media/base/audio_decoder_config.h"
#include "media/base/audio_renderer.h"
+#include "media/base/cdm_context.h"
#include "media/base/decoder_buffer.h"
#include "media/base/decryptor.h"
#include "media/base/demuxer.h"
@@ -127,7 +129,7 @@ class MockVideoRenderer : public VideoRenderer {
MOCK_METHOD9(Initialize,
void(DemuxerStream* stream,
const PipelineStatusCB& init_cb,
- const SetDecryptorReadyCB& set_decryptor_ready_cb,
+ const SetCdmReadyCB& set_cdm_ready_cb,
const StatisticsCB& statistics_cb,
const BufferingStateCB& buffering_state_cb,
const base::Closure& ended_cb,
@@ -151,7 +153,7 @@ class MockAudioRenderer : public AudioRenderer {
MOCK_METHOD8(Initialize,
void(DemuxerStream* stream,
const PipelineStatusCB& init_cb,
- const SetDecryptorReadyCB& set_decryptor_ready_cb,
+ const SetCdmReadyCB& set_cdm_ready_cb,
const StatisticsCB& statistics_cb,
const BufferingStateCB& buffering_state_cb,
const base::Closure& ended_cb,
@@ -259,6 +261,18 @@ class MockDecryptor : public Decryptor {
DISALLOW_COPY_AND_ASSIGN(MockDecryptor);
};
+class MockCdmContext : public CdmContext {
+ public:
+ MockCdmContext();
+ ~MockCdmContext() override;
+
+ MOCK_METHOD0(GetDecryptor, Decryptor*());
+ int GetCdmId() const override;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(MockCdmContext);
+};
+
} // namespace media
#endif // MEDIA_BASE_MOCK_FILTERS_H_

Powered by Google App Engine
This is Rietveld 408576698