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

Unified Diff: media/base/media_tracks.cc

Issue 1906423005: Replace scoped_ptr with std::unique_ptr in //media/base. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: scopedptr-media-base: . 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 side-by-side diff with in-line comments
Download patch
Index: media/base/media_tracks.cc
diff --git a/media/base/media_tracks.cc b/media/base/media_tracks.cc
index 832e5a822b12a497f43d01aabc9ef898c55fb7d0..367bd01b3878b4a341be6c23966c4b25e76e7e9a 100644
--- a/media/base/media_tracks.cc
+++ b/media/base/media_tracks.cc
@@ -5,6 +5,7 @@
#include "media/base/media_tracks.h"
#include "base/bind.h"
+#include "base/memory/ptr_util.h"
#include "media/base/audio_decoder_config.h"
#include "media/base/video_decoder_config.h"
@@ -21,7 +22,7 @@ void MediaTracks::AddAudioTrack(const AudioDecoderConfig& config,
const std::string& language) {
DCHECK(config.IsValidConfig());
CHECK(audio_configs_.find(id) == audio_configs_.end());
- scoped_ptr<MediaTrack> track = make_scoped_ptr(
+ std::unique_ptr<MediaTrack> track = base::WrapUnique(
new MediaTrack(MediaTrack::Audio, id, kind, label, language));
tracks_.push_back(std::move(track));
audio_configs_[id] = config;
@@ -34,7 +35,7 @@ void MediaTracks::AddVideoTrack(const VideoDecoderConfig& config,
const std::string& language) {
DCHECK(config.IsValidConfig());
CHECK(video_configs_.find(id) == video_configs_.end());
- scoped_ptr<MediaTrack> track = make_scoped_ptr(
+ std::unique_ptr<MediaTrack> track = base::WrapUnique(
new MediaTrack(MediaTrack::Video, id, kind, label, language));
tracks_.push_back(std::move(track));
video_configs_[id] = config;

Powered by Google App Engine
This is Rietveld 408576698