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

Unified Diff: remoting/test/test_chromoting_client.cc

Issue 1864213002: Convert //remoting to use std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Mac IWYU 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
« no previous file with comments | « remoting/test/test_chromoting_client.h ('k') | remoting/test/test_chromoting_client_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/test/test_chromoting_client.cc
diff --git a/remoting/test/test_chromoting_client.cc b/remoting/test/test_chromoting_client.cc
index 64625ce2cdbd53f68b709d203e6f1f2bfe711fb0..cd9309d6049a31a152c2cf14e3775770f8bf8011 100644
--- a/remoting/test/test_chromoting_client.cc
+++ b/remoting/test/test_chromoting_client.cc
@@ -9,6 +9,7 @@
#include <vector>
#include "base/logging.h"
+#include "base/memory/ptr_util.h"
#include "base/thread_task_runner_handle.h"
#include "jingle/glue/thread_wrapper.h"
#include "net/base/request_priority.h"
@@ -63,7 +64,7 @@ TestChromotingClient::TestChromotingClient()
: TestChromotingClient(nullptr) {}
TestChromotingClient::TestChromotingClient(
- scoped_ptr<protocol::VideoRenderer> video_renderer)
+ std::unique_ptr<protocol::VideoRenderer> video_renderer)
: connection_to_host_state_(protocol::ConnectionToHost::INITIALIZING),
connection_error_code_(protocol::OK),
video_renderer_(std::move(video_renderer)) {}
@@ -121,8 +122,8 @@ void TestChromotingClient::StartConnection(
scoped_refptr<protocol::TransportContext> transport_context(
new protocol::TransportContext(
signal_strategy_.get(),
- make_scoped_ptr(new protocol::ChromiumPortAllocatorFactory()),
- make_scoped_ptr(
+ base::WrapUnique(new protocol::ChromiumPortAllocatorFactory()),
+ base::WrapUnique(
new ChromiumUrlRequestFactory(request_context_getter)),
network_settings, protocol::TransportRole::CLIENT));
@@ -177,12 +178,12 @@ void TestChromotingClient::RemoveRemoteConnectionObserver(
}
void TestChromotingClient::SetSignalStrategyForTests(
- scoped_ptr<SignalStrategy> signal_strategy) {
+ std::unique_ptr<SignalStrategy> signal_strategy) {
signal_strategy_ = std::move(signal_strategy);
}
void TestChromotingClient::SetConnectionToHostForTests(
- scoped_ptr<protocol::ConnectionToHost> connection_to_host) {
+ std::unique_ptr<protocol::ConnectionToHost> connection_to_host) {
test_connection_to_host_ = std::move(connection_to_host);
}
« no previous file with comments | « remoting/test/test_chromoting_client.h ('k') | remoting/test/test_chromoting_client_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698