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

Unified Diff: remoting/host/gcd_rest_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/host/gcd_rest_client.h ('k') | remoting/host/gcd_rest_client_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/host/gcd_rest_client.cc
diff --git a/remoting/host/gcd_rest_client.cc b/remoting/host/gcd_rest_client.cc
index d98553856b9d46cec0aa65dcc0bf20dc8ab61c2a..eba4d391e4f094430c2c761168fdb49d9e655b81 100644
--- a/remoting/host/gcd_rest_client.cc
+++ b/remoting/host/gcd_rest_client.cc
@@ -34,7 +34,7 @@ GcdRestClient::GcdRestClient(const std::string& gcd_base_url,
GcdRestClient::~GcdRestClient() {}
void GcdRestClient::PatchState(
- scoped_ptr<base::DictionaryValue> patch_details,
+ std::unique_ptr<base::DictionaryValue> patch_details,
const GcdRestClient::ResultCallback& callback) {
DCHECK(!HasPendingRequest());
@@ -54,9 +54,9 @@ void GcdRestClient::PatchState(
// value because |DictionaryValue| doesn't support int64_t values, and
// GCD doesn't accept fractional values.
double now = clock_->Now().ToJavaTime();
- scoped_ptr<base::DictionaryValue> patch_dict(new base::DictionaryValue);
+ std::unique_ptr<base::DictionaryValue> patch_dict(new base::DictionaryValue);
patch_dict->SetDouble("requestTimeMs", now);
- scoped_ptr<base::ListValue> patch_list(new base::ListValue);
+ std::unique_ptr<base::ListValue> patch_list(new base::ListValue);
base::DictionaryValue* patch_item = new base::DictionaryValue;
patch_list->Append(patch_item);
patch_item->Set("patch", std::move(patch_details));
@@ -88,7 +88,7 @@ void GcdRestClient::PatchState(
base::Bind(&GcdRestClient::OnTokenReceived, base::Unretained(this)));
}
-void GcdRestClient::SetClockForTest(scoped_ptr<base::Clock> clock) {
+void GcdRestClient::SetClockForTest(std::unique_ptr<base::Clock> clock) {
clock_ = std::move(clock);
}
« no previous file with comments | « remoting/host/gcd_rest_client.h ('k') | remoting/host/gcd_rest_client_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698