| OLD | NEW |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. Use of this | 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. Use of this |
| 2 // source code is governed by a BSD-style license that can be found in the | 2 // source code is governed by a BSD-style license that can be found in the |
| 3 // LICENSE file. | 3 // LICENSE file. |
| 4 | 4 |
| 5 #ifndef MEDIA_BASE_MOCK_PIPELINE_H_ | 5 #ifndef MEDIA_BASE_MOCK_PIPELINE_H_ |
| 6 #define MEDIA_BASE_MOCK_PIPELINE_H_ | 6 #define MEDIA_BASE_MOCK_PIPELINE_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "media/base/media_format.h" | 10 #include "media/base/media_format.h" |
| (...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 60 } | 60 } |
| 61 | 61 |
| 62 virtual base::TimeDelta GetInterpolatedTime() const { | 62 virtual base::TimeDelta GetInterpolatedTime() const { |
| 63 return time_; | 63 return time_; |
| 64 } | 64 } |
| 65 | 65 |
| 66 virtual PipelineError GetError() const { | 66 virtual PipelineError GetError() const { |
| 67 return error_; | 67 return error_; |
| 68 } | 68 } |
| 69 | 69 |
| 70 virtual bool IsRendered(const std::string&) const { |
| 71 return true; |
| 72 } |
| 73 |
| 70 // Implementation of Pipeline interface. | 74 // Implementation of Pipeline interface. |
| 71 virtual bool Start(FilterFactory* filter_factory, | 75 virtual bool Start(FilterFactory* filter_factory, |
| 72 const std::string& url, | 76 const std::string& url, |
| 73 Callback1<bool>::Type* init_complete_callback) { | 77 Callback1<bool>::Type* init_complete_callback) { |
| 74 EXPECT_FALSE(initialized_); | 78 EXPECT_FALSE(initialized_); |
| 75 initialized_ = true; | 79 initialized_ = true; |
| 76 if (init_complete_callback) { | 80 if (init_complete_callback) { |
| 77 init_complete_callback->Run(true); | 81 init_complete_callback->Run(true); |
| 78 delete init_complete_callback; | 82 delete init_complete_callback; |
| 79 } | 83 } |
| (...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 164 size_t height_; | 168 size_t height_; |
| 165 int64 buffered_bytes_; | 169 int64 buffered_bytes_; |
| 166 int64 total_bytes_; | 170 int64 total_bytes_; |
| 167 | 171 |
| 168 DISALLOW_COPY_AND_ASSIGN(MockPipeline); | 172 DISALLOW_COPY_AND_ASSIGN(MockPipeline); |
| 169 }; | 173 }; |
| 170 | 174 |
| 171 } // namespace media | 175 } // namespace media |
| 172 | 176 |
| 173 #endif // MEDIA_BASE_MOCK_PIPELINE_H_ | 177 #endif // MEDIA_BASE_MOCK_PIPELINE_H_ |
| OLD | NEW |