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

Unified Diff: chrome/browser/extensions/api/messaging/native_messaging_test_util.cc

Issue 1871713002: Convert //chrome/browser/extensions from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase and fix header 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: chrome/browser/extensions/api/messaging/native_messaging_test_util.cc
diff --git a/chrome/browser/extensions/api/messaging/native_messaging_test_util.cc b/chrome/browser/extensions/api/messaging/native_messaging_test_util.cc
index 9e70389e06563e0c6321558172e0c8c3450fa1da..0c694477a6257c19bcdd1d3df96f767e593664b3 100644
--- a/chrome/browser/extensions/api/messaging/native_messaging_test_util.cc
+++ b/chrome/browser/extensions/api/messaging/native_messaging_test_util.cc
@@ -4,9 +4,10 @@
#include "chrome/browser/extensions/api/messaging/native_messaging_test_util.h"
+#include <memory>
+
#include "base/files/file_path.h"
#include "base/json/json_file_value_serializer.h"
-#include "base/memory/scoped_ptr.h"
#include "base/path_service.h"
#include "base/strings/stringprintf.h"
#include "base/strings/utf_string_conversions.h"
@@ -27,13 +28,13 @@ void WriteTestNativeHostManifest(const base::FilePath& target_dir,
const std::string& host_name,
const base::FilePath& host_path,
bool user_level) {
- scoped_ptr<base::DictionaryValue> manifest(new base::DictionaryValue());
+ std::unique_ptr<base::DictionaryValue> manifest(new base::DictionaryValue());
manifest->SetString("name", host_name);
manifest->SetString("description", "Native Messaging Echo Test");
manifest->SetString("type", "stdio");
manifest->SetString("path", host_path.AsUTF8Unsafe());
- scoped_ptr<base::ListValue> origins(new base::ListValue());
+ std::unique_ptr<base::ListValue> origins(new base::ListValue());
origins->AppendString(base::StringPrintf(
"chrome-extension://%s/", ScopedTestNativeMessagingHost::kExtensionId));
manifest->Set("allowed_origins", origins.release());

Powered by Google App Engine
This is Rietveld 408576698