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

Unified Diff: remoting/host/video_frame_recorder.cc

Issue 1549493004: Use std::move() instead of .Pass() in remoting/host (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@move_not_pass
Patch Set: Created 5 years 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: remoting/host/video_frame_recorder.cc
diff --git a/remoting/host/video_frame_recorder.cc b/remoting/host/video_frame_recorder.cc
index c286e39bb47cb229885ce0aa84aa915b5cf0735b..24b5cdbc099b36761701aaebfd6b91c675d8a0ae 100644
--- a/remoting/host/video_frame_recorder.cc
+++ b/remoting/host/video_frame_recorder.cc
@@ -59,7 +59,7 @@ VideoFrameRecorder::RecordingVideoEncoder::RecordingVideoEncoder(
scoped_ptr<VideoEncoder> encoder,
scoped_refptr<base::TaskRunner> recorder_task_runner,
base::WeakPtr<VideoFrameRecorder> recorder)
- : encoder_(encoder.Pass()),
+ : encoder_(std::move(encoder)),
recorder_task_runner_(recorder_task_runner),
recorder_(recorder),
enable_recording_(false),
@@ -133,12 +133,12 @@ scoped_ptr<VideoEncoder> VideoFrameRecorder::WrapVideoEncoder(
caller_task_runner_ = base::ThreadTaskRunnerHandle::Get();
scoped_ptr<RecordingVideoEncoder> recording_encoder(
- new RecordingVideoEncoder(encoder.Pass(),
+ new RecordingVideoEncoder(std::move(encoder),
caller_task_runner_,
weak_factory_.GetWeakPtr()));
recording_encoder_ = recording_encoder->AsWeakPtr();
- return recording_encoder.Pass();
+ return std::move(recording_encoder);
}
void VideoFrameRecorder::DetachVideoEncoderWrapper() {
@@ -200,7 +200,7 @@ scoped_ptr<webrtc::DesktopFrame> VideoFrameRecorder::NextFrame() {
DCHECK_GE(content_bytes_, 0);
}
- return frame.Pass();
+ return frame;
}
void VideoFrameRecorder::SetEncoderTaskRunner(

Powered by Google App Engine
This is Rietveld 408576698