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

Unified Diff: media/base/mock_filters.h

Issue 1935873002: Implement disabling and enabling media tracks (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@track-control2
Patch Set: rebase Created 4 years, 6 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/fake_text_track_stream.cc ('k') | media/base/pipeline.h » ('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 03f020ade154cb2984ff01133eacc8874393b096..ecd6848583b86edbaad21c95921786dc91fd29b4 100644
--- a/media/base/mock_filters.h
+++ b/media/base/mock_filters.h
@@ -19,6 +19,7 @@
#include "media/base/decoder_buffer.h"
#include "media/base/decryptor.h"
#include "media/base/demuxer.h"
+#include "media/base/media_track.h"
#include "media/base/pipeline.h"
#include "media/base/pipeline_status.h"
#include "media/base/renderer.h"
@@ -73,6 +74,11 @@ class MockPipeline : public Pipeline {
base::TimeDelta,
const PipelineStatusCB&));
+ MOCK_METHOD1(OnEnabledAudioTracksChanged,
+ void(const std::vector<MediaTrack::Id>&));
+ MOCK_METHOD1(OnSelectedVideoTrackChanged,
+ void(const std::vector<MediaTrack::Id>&));
+
// TODO(sandersd): This should automatically return true between Start() and
// Stop(). (Or better, remove it from the interface entirely.)
MOCK_CONST_METHOD0(IsRunning, bool());
@@ -122,6 +128,10 @@ class MockDemuxer : public Demuxer {
MOCK_CONST_METHOD0(GetStartTime, base::TimeDelta());
MOCK_CONST_METHOD0(GetTimelineOffset, base::Time());
MOCK_CONST_METHOD0(GetMemoryUsage, int64_t());
+ MOCK_METHOD2(OnEnabledAudioTracksChanged,
+ void(const std::vector<MediaTrack::Id>&, base::TimeDelta));
+ MOCK_METHOD2(OnSelectedVideoTrackChanged,
+ void(const std::vector<MediaTrack::Id>&, base::TimeDelta));
private:
DISALLOW_COPY_AND_ASSIGN(MockDemuxer);
@@ -146,6 +156,9 @@ class MockDemuxerStream : public DemuxerStream {
void set_liveness(Liveness liveness);
VideoRotation video_rotation() override;
+ MOCK_CONST_METHOD0(enabled, bool());
+ MOCK_METHOD2(set_enabled, void(bool, base::TimeDelta));
+ MOCK_METHOD1(SetStreamRestartedCB, void(const StreamRestartedCB&));
private:
Type type_;
« no previous file with comments | « media/base/fake_text_track_stream.cc ('k') | media/base/pipeline.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698