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

Unified Diff: cc/debug/micro_benchmark_controller.cc

Issue 608503005: Revert of cc: Remove use of PassAs() and constructor-casting with scoped_ptr. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 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 | « cc/blink/web_transform_animation_curve_impl.cc ('k') | cc/debug/micro_benchmark_controller_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/debug/micro_benchmark_controller.cc
diff --git a/cc/debug/micro_benchmark_controller.cc b/cc/debug/micro_benchmark_controller.cc
index bf98100541921966b6b236ad869c7a169ecc1253..8b20bdf197f7ddfc9e157329bab5ec5cae178915 100644
--- a/cc/debug/micro_benchmark_controller.cc
+++ b/cc/debug/micro_benchmark_controller.cc
@@ -28,16 +28,19 @@
scoped_ptr<base::Value> value,
const MicroBenchmark::DoneCallback& callback) {
if (name == "invalidation_benchmark") {
- return make_scoped_ptr(new InvalidationBenchmark(value.Pass(), callback));
+ return scoped_ptr<MicroBenchmark>(
+ new InvalidationBenchmark(value.Pass(), callback));
} else if (name == "picture_record_benchmark") {
- return make_scoped_ptr(new PictureRecordBenchmark(value.Pass(), callback));
+ return scoped_ptr<MicroBenchmark>(
+ new PictureRecordBenchmark(value.Pass(), callback));
} else if (name == "rasterize_and_record_benchmark") {
- return make_scoped_ptr(
+ return scoped_ptr<MicroBenchmark>(
new RasterizeAndRecordBenchmark(value.Pass(), callback));
} else if (name == "unittest_only_benchmark") {
- return make_scoped_ptr(new UnittestOnlyBenchmark(value.Pass(), callback));
+ return scoped_ptr<MicroBenchmark>(
+ new UnittestOnlyBenchmark(value.Pass(), callback));
}
- return nullptr;
+ return scoped_ptr<MicroBenchmark>();
}
class IsDonePredicate {
« no previous file with comments | « cc/blink/web_transform_animation_curve_impl.cc ('k') | cc/debug/micro_benchmark_controller_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698