| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "media/base/filters.h" | 5 #include "media/base/filters.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 | 8 |
| 9 namespace media { | 9 namespace media { |
| 10 | 10 |
| (...skipping 11 matching lines...) Expand all Loading... |
| 22 DCHECK(!cb->is_null()); | 22 DCHECK(!cb->is_null()); |
| 23 base::Closure tmp_cb(*cb); | 23 base::Closure tmp_cb(*cb); |
| 24 cb->Reset(); | 24 cb->Reset(); |
| 25 tmp_cb.Run(); | 25 tmp_cb.Run(); |
| 26 } | 26 } |
| 27 | 27 |
| 28 Filter::Filter() : host_(NULL) {} | 28 Filter::Filter() : host_(NULL) {} |
| 29 | 29 |
| 30 Filter::~Filter() {} | 30 Filter::~Filter() {} |
| 31 | 31 |
| 32 void Filter::clear_host() { |
| 33 DCHECK(host_); |
| 34 host_ = NULL; |
| 35 } |
| 36 |
| 32 void Filter::set_host(FilterHost* host) { | 37 void Filter::set_host(FilterHost* host) { |
| 33 DCHECK(host); | 38 DCHECK(host); |
| 34 DCHECK(!host_); | 39 DCHECK(!host_); |
| 35 host_ = host; | 40 host_ = host; |
| 36 } | 41 } |
| 37 | 42 |
| 38 FilterHost* Filter::host() { | 43 FilterHost* Filter::host() { |
| 39 return host_; | 44 return host_; |
| 40 } | 45 } |
| 41 | 46 |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 75 | 80 |
| 76 AudioDecoder::AudioDecoder() {} | 81 AudioDecoder::AudioDecoder() {} |
| 77 | 82 |
| 78 AudioDecoder::~AudioDecoder() {} | 83 AudioDecoder::~AudioDecoder() {} |
| 79 | 84 |
| 80 void AudioDecoder::ConsumeAudioSamples(scoped_refptr<Buffer> buffer) { | 85 void AudioDecoder::ConsumeAudioSamples(scoped_refptr<Buffer> buffer) { |
| 81 consume_audio_samples_callback_.Run(buffer); | 86 consume_audio_samples_callback_.Run(buffer); |
| 82 } | 87 } |
| 83 | 88 |
| 84 } // namespace media | 89 } // namespace media |
| OLD | NEW |