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

Unified Diff: chrome/browser/ui/webui/inspect_ui.cc

Issue 377723003: Remove some unnecessary heap allocations and copies. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: devtools only Created 6 years, 5 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 | « chrome/browser/ui/webui/inspect_ui.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/webui/inspect_ui.cc
diff --git a/chrome/browser/ui/webui/inspect_ui.cc b/chrome/browser/ui/webui/inspect_ui.cc
index 43038c168a66efcb6cd90cc39b78bf6b30e0dec4..70401b16d2f3d57fa6c5820259aaadf15b7ec924 100644
--- a/chrome/browser/ui/webui/inspect_ui.cc
+++ b/chrome/browser/ui/webui/inspect_ui.cc
@@ -476,12 +476,10 @@ DevToolsTargetImpl* InspectUI::FindTarget(
}
void InspectUI::PopulateTargets(const std::string& source,
- scoped_ptr<base::ListValue> targets) {
- scoped_ptr<base::Value> source_value(base::Value::CreateStringValue(source));
- web_ui()->CallJavascriptFunction(
- "populateTargets",
- *source_value.get(),
- *targets.get());
+ const base::ListValue& targets) {
+ web_ui()->CallJavascriptFunction("populateTargets",
+ base::StringValue(source),
+ targets);
}
void InspectUI::PopulatePortStatus(const base::Value& status) {
« no previous file with comments | « chrome/browser/ui/webui/inspect_ui.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698