| Index: media/filters/decrypting_audio_decoder.cc
|
| diff --git a/media/filters/decrypting_audio_decoder.cc b/media/filters/decrypting_audio_decoder.cc
|
| index 3425d0c29e02a9b925ba6f0e162e8f3a972599dd..905868999db75f32579b3f2f92b5d4e1666a6f36 100644
|
| --- a/media/filters/decrypting_audio_decoder.cc
|
| +++ b/media/filters/decrypting_audio_decoder.cc
|
| @@ -7,6 +7,7 @@
|
| #include <cstdlib>
|
|
|
| #include "base/bind.h"
|
| +#include "base/bind_to_current_loop.h"
|
| #include "base/callback_helpers.h"
|
| #include "base/location.h"
|
| #include "base/logging.h"
|
| @@ -14,7 +15,6 @@
|
| #include "media/base/audio_buffer.h"
|
| #include "media/base/audio_decoder_config.h"
|
| #include "media/base/audio_timestamp_helper.h"
|
| -#include "media/base/bind_to_current_loop.h"
|
| #include "media/base/buffers.h"
|
| #include "media/base/decoder_buffer.h"
|
| #include "media/base/decryptor.h"
|
| @@ -58,8 +58,8 @@ void DecryptingAudioDecoder::Initialize(const AudioDecoderConfig& config,
|
| DCHECK(reset_cb_.is_null());
|
|
|
| weak_this_ = weak_factory_.GetWeakPtr();
|
| - init_cb_ = BindToCurrentLoop(status_cb);
|
| - output_cb_ = BindToCurrentLoop(output_cb);
|
| + init_cb_ = base::BindToCurrentLoop(status_cb);
|
| + output_cb_ = base::BindToCurrentLoop(output_cb);
|
|
|
| if (!config.IsValidConfig()) {
|
| DLOG(ERROR) << "Invalid audio stream config.";
|
| @@ -77,7 +77,7 @@ void DecryptingAudioDecoder::Initialize(const AudioDecoderConfig& config,
|
|
|
| if (state_ == kUninitialized) {
|
| state_ = kDecryptorRequested;
|
| - set_decryptor_ready_cb_.Run(BindToCurrentLoop(
|
| + set_decryptor_ready_cb_.Run(base::BindToCurrentLoop(
|
| base::Bind(&DecryptingAudioDecoder::SetDecryptor, weak_this_)));
|
| return;
|
| }
|
| @@ -95,7 +95,7 @@ void DecryptingAudioDecoder::Decode(const scoped_refptr<DecoderBuffer>& buffer,
|
| DCHECK(!decode_cb.is_null());
|
| CHECK(decode_cb_.is_null()) << "Overlapping decodes are not supported.";
|
|
|
| - decode_cb_ = BindToCurrentLoop(decode_cb);
|
| + decode_cb_ = base::BindToCurrentLoop(decode_cb);
|
|
|
| // Return empty (end-of-stream) frames if decoding has finished.
|
| if (state_ == kDecodeFinished) {
|
| @@ -126,7 +126,7 @@ void DecryptingAudioDecoder::Reset(const base::Closure& closure) {
|
| DCHECK(init_cb_.is_null()); // No Reset() during pending initialization.
|
| DCHECK(reset_cb_.is_null());
|
|
|
| - reset_cb_ = BindToCurrentLoop(closure);
|
| + reset_cb_ = base::BindToCurrentLoop(closure);
|
|
|
| decryptor_->ResetDecoder(Decryptor::kAudio);
|
|
|
| @@ -199,7 +199,7 @@ void DecryptingAudioDecoder::InitializeDecoder() {
|
| state_ = kPendingDecoderInit;
|
| decryptor_->InitializeAudioDecoder(
|
| config_,
|
| - BindToCurrentLoop(base::Bind(
|
| + base::BindToCurrentLoop(base::Bind(
|
| &DecryptingAudioDecoder::FinishInitialization, weak_this_)));
|
| }
|
|
|
| @@ -224,7 +224,7 @@ void DecryptingAudioDecoder::FinishInitialization(bool success) {
|
|
|
| decryptor_->RegisterNewKeyCB(
|
| Decryptor::kAudio,
|
| - BindToCurrentLoop(
|
| + base::BindToCurrentLoop(
|
| base::Bind(&DecryptingAudioDecoder::OnKeyAdded, weak_this_)));
|
|
|
| state_ = kIdle;
|
| @@ -242,7 +242,7 @@ void DecryptingAudioDecoder::DecodePendingBuffer() {
|
|
|
| decryptor_->DecryptAndDecodeAudio(
|
| pending_buffer_to_decode_,
|
| - BindToCurrentLoop(base::Bind(
|
| + base::BindToCurrentLoop(base::Bind(
|
| &DecryptingAudioDecoder::DeliverFrame, weak_this_, buffer_size)));
|
| }
|
|
|
|
|