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

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

Issue 1904213003: Convert //media/filters from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remove include Created 4 years, 8 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
« no previous file with comments | « media/filters/decoder_stream.cc ('k') | media/filters/decrypting_audio_decoder_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 <memory>
9
8 #include "base/callback.h" 10 #include "base/callback.h"
9 #include "base/macros.h" 11 #include "base/macros.h"
10 #include "base/memory/ref_counted.h" 12 #include "base/memory/ref_counted.h"
11 #include "base/memory/scoped_ptr.h"
12 #include "base/memory/weak_ptr.h" 13 #include "base/memory/weak_ptr.h"
13 #include "base/time/time.h" 14 #include "base/time/time.h"
14 #include "media/base/audio_decoder.h" 15 #include "media/base/audio_decoder.h"
15 #include "media/base/cdm_context.h" 16 #include "media/base/cdm_context.h"
16 #include "media/base/decryptor.h" 17 #include "media/base/decryptor.h"
17 #include "media/base/demuxer_stream.h" 18 #include "media/base/demuxer_stream.h"
18 19
19 namespace base { 20 namespace base {
20 class SingleThreadTaskRunner; 21 class SingleThreadTaskRunner;
21 } 22 }
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
107 // The buffer that needs decrypting/decoding. 108 // The buffer that needs decrypting/decoding.
108 scoped_refptr<media::DecoderBuffer> pending_buffer_to_decode_; 109 scoped_refptr<media::DecoderBuffer> pending_buffer_to_decode_;
109 110
110 // Indicates the situation where new key is added during pending decode 111 // Indicates the situation where new key is added during pending decode
111 // (in other words, this variable can only be set in state kPendingDecode). 112 // (in other words, this variable can only be set in state kPendingDecode).
112 // If this variable is true and kNoKey is returned then we need to try 113 // If this variable is true and kNoKey is returned then we need to try
113 // decrypting/decoding again in case the newly added key is the correct 114 // decrypting/decoding again in case the newly added key is the correct
114 // decryption key. 115 // decryption key.
115 bool key_added_while_decode_pending_; 116 bool key_added_while_decode_pending_;
116 117
117 scoped_ptr<AudioTimestampHelper> timestamp_helper_; 118 std::unique_ptr<AudioTimestampHelper> timestamp_helper_;
118 119
119 base::WeakPtr<DecryptingAudioDecoder> weak_this_; 120 base::WeakPtr<DecryptingAudioDecoder> weak_this_;
120 base::WeakPtrFactory<DecryptingAudioDecoder> weak_factory_; 121 base::WeakPtrFactory<DecryptingAudioDecoder> weak_factory_;
121 122
122 DISALLOW_COPY_AND_ASSIGN(DecryptingAudioDecoder); 123 DISALLOW_COPY_AND_ASSIGN(DecryptingAudioDecoder);
123 }; 124 };
124 125
125 } // namespace media 126 } // namespace media
126 127
127 #endif // MEDIA_FILTERS_DECRYPTING_AUDIO_DECODER_H_ 128 #endif // MEDIA_FILTERS_DECRYPTING_AUDIO_DECODER_H_
OLDNEW
« no previous file with comments | « media/filters/decoder_stream.cc ('k') | media/filters/decrypting_audio_decoder_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698