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

Unified Diff: bench/FontScalerBench.cpp

Issue 23876006: Refactoring: get rid of the SkBenchmark void* parameter. (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: sync to head Created 7 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 | « bench/FontCacheBench.cpp ('k') | bench/GameBench.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: bench/FontScalerBench.cpp
diff --git a/bench/FontScalerBench.cpp b/bench/FontScalerBench.cpp
index ac4f60ec3250b1f5dfca6312d61ee14eaccb5046..d4a9674bccdee5ec3af9cebcdb4ed798327b3f99 100644
--- a/bench/FontScalerBench.cpp
+++ b/bench/FontScalerBench.cpp
@@ -19,7 +19,7 @@ class FontScalerBench : public SkBenchmark {
SkString fText;
bool fDoLCD;
public:
- FontScalerBench(void* param, bool doLCD) : INHERITED(param) {
+ FontScalerBench(bool doLCD) {
fName.printf("fontscaler_%s", doLCD ? "lcd" : "aa");
fText.set("abcdefghijklmnopqrstuvwxyz01234567890");
fDoLCD = doLCD;
@@ -55,8 +55,5 @@ private:
///////////////////////////////////////////////////////////////////////////////
-static SkBenchmark* Fact0(void* p) { return SkNEW_ARGS(FontScalerBench, (p, false)); }
-static SkBenchmark* Fact1(void* p) { return SkNEW_ARGS(FontScalerBench, (p, true)); }
-
-static BenchRegistry gReg0(Fact0);
-static BenchRegistry gReg1(Fact1);
+DEF_BENCH( return SkNEW_ARGS(FontScalerBench, (false)); )
+DEF_BENCH( return SkNEW_ARGS(FontScalerBench, (true)); )
« no previous file with comments | « bench/FontCacheBench.cpp ('k') | bench/GameBench.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698