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

Unified Diff: chrome/browser/ui/webui/chromeos/network_ui.cc

Issue 2392693002: Rewrite simple uses of base::ListValue::Append(base::Value*) on CrOS. (Closed)
Patch Set: MakeUnique Created 4 years, 2 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/ui/webui/chromeos/network_ui.cc
diff --git a/chrome/browser/ui/webui/chromeos/network_ui.cc b/chrome/browser/ui/webui/chromeos/network_ui.cc
index 0d4e2adf07c7ae102ba4aa1a66a57b779b6ab128..8c105fd89e6ed791c59d3a7c37d73c32b882cf5b 100644
--- a/chrome/browser/ui/webui/chromeos/network_ui.cc
+++ b/chrome/browser/ui/webui/chromeos/network_ui.cc
@@ -5,6 +5,7 @@
#include "chrome/browser/ui/webui/chromeos/network_ui.h"
#include <string>
+#include <utility>
#include "base/macros.h"
#include "base/memory/weak_ptr.h"
@@ -118,7 +119,7 @@ class NetworkConfigMessageHandler : public content::WebUIMessageHandler {
SetDeviceProperties(dictionary_copy.get());
base::ListValue return_arg_list;
- return_arg_list.Append(dictionary_copy.release());
+ return_arg_list.Append(std::move(dictionary_copy));
web_ui()->CallJavascriptFunctionUnsafe("NetworkUI.getShillPropertiesResult",
return_arg_list);
}
@@ -132,7 +133,7 @@ class NetworkConfigMessageHandler : public content::WebUIMessageHandler {
std::unique_ptr<base::DictionaryValue> dictionary;
dictionary->SetStringWithoutPathExpansion(shill::kGuidProperty, guid);
dictionary->SetStringWithoutPathExpansion("ShillError", error_name);
- return_arg_list.Append(dictionary.release());
+ return_arg_list.Append(std::move(dictionary));
web_ui()->CallJavascriptFunctionUnsafe("NetworkUI.getShillPropertiesResult",
return_arg_list);
}
« no previous file with comments | « chrome/browser/ui/webui/chromeos/login/user_image_screen_handler.cc ('k') | chrome/browser/ui/webui/chromeos/power_ui.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698