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

Side by Side Diff: media/filters/decrypting_audio_decoder.h

Issue 416333011: Allow setContentDecryptionModule() to get called when setting is done. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 4 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #ifndef MEDIA_FILTERS_DECRYPTING_AUDIO_DECODER_H_ 5 #ifndef MEDIA_FILTERS_DECRYPTING_AUDIO_DECODER_H_
6 #define MEDIA_FILTERS_DECRYPTING_AUDIO_DECODER_H_ 6 #define MEDIA_FILTERS_DECRYPTING_AUDIO_DECODER_H_
7 7
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/memory/ref_counted.h" 9 #include "base/memory/ref_counted.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 kDecryptorRequested, 60 kDecryptorRequested,
61 kPendingDecoderInit, 61 kPendingDecoderInit,
62 kIdle, 62 kIdle,
63 kPendingDecode, 63 kPendingDecode,
64 kWaitingForKey, 64 kWaitingForKey,
65 kDecodeFinished, 65 kDecodeFinished,
66 kError 66 kError
67 }; 67 };
68 68
69 // Callback for DecryptorHost::RequestDecryptor(). 69 // Callback for DecryptorHost::RequestDecryptor().
70 void SetDecryptor(Decryptor* decryptor); 70 void SetDecryptor(Decryptor* decryptor, base::Closure done_cb);
71 71
72 // Initializes the audio decoder on the |decryptor_| with |config_|. 72 // Initializes the audio decoder on the |decryptor_| with |config_|.
73 void InitializeDecoder(); 73 void InitializeDecoder();
74 74
75 // Callback for Decryptor::InitializeAudioDecoder() during initialization. 75 // Callback for Decryptor::InitializeAudioDecoder() during initialization.
76 void FinishInitialization(bool success); 76 void FinishInitialization(bool success);
77 77
78 void DecodePendingBuffer(); 78 void DecodePendingBuffer();
79 79
80 // Callback for Decryptor::DecryptAndDecodeAudio(). 80 // Callback for Decryptor::DecryptAndDecodeAudio().
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
124 // NOTE: Weak pointers must be invalidated before all other member variables. 124 // NOTE: Weak pointers must be invalidated before all other member variables.
125 base::WeakPtrFactory<DecryptingAudioDecoder> weak_factory_; 125 base::WeakPtrFactory<DecryptingAudioDecoder> weak_factory_;
126 base::WeakPtr<DecryptingAudioDecoder> weak_this_; 126 base::WeakPtr<DecryptingAudioDecoder> weak_this_;
127 127
128 DISALLOW_COPY_AND_ASSIGN(DecryptingAudioDecoder); 128 DISALLOW_COPY_AND_ASSIGN(DecryptingAudioDecoder);
129 }; 129 };
130 130
131 } // namespace media 131 } // namespace media
132 132
133 #endif // MEDIA_FILTERS_DECRYPTING_AUDIO_DECODER_H_ 133 #endif // MEDIA_FILTERS_DECRYPTING_AUDIO_DECODER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698