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

Unified Diff: media/base/mock_filters.cc

Issue 9968117: Move Demuxer::set_host() to Initialize(). (Closed) Base URL: svn://chrome-svn/chrome/trunk/src
Patch Set: fixes Created 8 years, 9 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/mock_filters.h ('k') | media/base/pipeline.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/base/mock_filters.cc
diff --git a/media/base/mock_filters.cc b/media/base/mock_filters.cc
index 3502973baa4366d8146030bff7edd75344e1e2dd..258e39689e80d692ea861a3074b34eed3f7adc49 100644
--- a/media/base/mock_filters.cc
+++ b/media/base/mock_filters.cc
@@ -38,35 +38,10 @@ void MockDataSource::SetTotalAndBufferedBytes(int64 total_bytes,
buffered_bytes_ = buffered_bytes;
}
-MockDemuxer::MockDemuxer()
- : total_bytes_(-1), buffered_bytes_(-1), duration_() {
- EXPECT_CALL(*this, GetBitrate()).WillRepeatedly(Return(0));
- EXPECT_CALL(*this, IsLocalSource()).WillRepeatedly(Return(false));
- EXPECT_CALL(*this, IsSeekable()).WillRepeatedly(Return(false));
-}
+MockDemuxer::MockDemuxer() {}
MockDemuxer::~MockDemuxer() {}
-void MockDemuxer::set_host(DemuxerHost* demuxer_host) {
- Demuxer::set_host(demuxer_host);
-
- if (total_bytes_ > 0)
- host()->SetTotalBytes(total_bytes_);
-
- if (buffered_bytes_ > 0)
- host()->SetBufferedBytes(buffered_bytes_);
-
- if (duration_.InMilliseconds() > 0)
- host()->SetDuration(duration_);
-}
-
-void MockDemuxer::SetTotalAndBufferedBytesAndDuration(
- int64 total_bytes, int64 buffered_bytes, const base::TimeDelta& duration) {
- total_bytes_ = total_bytes;
- buffered_bytes_ = buffered_bytes;
- duration_ = duration;
-}
-
MockDemuxerStream::MockDemuxerStream() {}
MockDemuxerStream::~MockDemuxerStream() {}
« no previous file with comments | « media/base/mock_filters.h ('k') | media/base/pipeline.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698