diff options
author | 2013-08-30 15:52:46 +0000 | |
---|---|---|
committer | 2013-08-30 15:52:46 +0000 | |
commit | a6f37e77c1c95f0a06ac55ff659cb7b8dfabefcf (patch) | |
tree | 6310645cf497f908894d36bf749e47c53ef5233d /gm | |
parent | 06f05989570fbf2ced3d2d1690ea1276b7330b5f (diff) |
Add ShouldSkip variant that can read a --match flag directly.
Just seemed like we were going through lots of hoops for this common case.
BUG=
R=scroggo@google.com
Author: mtklein@google.com
Review URL: https://chromiumcodereview.appspot.com/23708009
git-svn-id: http://skia.googlecode.com/svn/trunk@11034 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'gm')
-rw-r--r-- | gm/gmmain.cpp | 11 |
1 files changed, 1 insertions, 10 deletions
diff --git a/gm/gmmain.cpp b/gm/gmmain.cpp index 6fd96f9d24..c24d9c70e4 100644 --- a/gm/gmmain.cpp +++ b/gm/gmmain.cpp @@ -2093,13 +2093,6 @@ static bool parse_flags_gmmain_paths(GMMain* gmmain) { return true; } -static bool parse_flags_match_strs(SkTDArray<const char*>* matchStrs) { - for (int i = 0; i < FLAGS_match.count(); ++i) { - matchStrs->push(FLAGS_match[i]); - } - return true; -} - static bool parse_flags_resource_path() { if (FLAGS_resourcePath.count() == 1) { GM::SetResourcePath(FLAGS_resourcePath[0]); @@ -2145,7 +2138,6 @@ int tool_main(int argc, char** argv) { #else GrContextFactory* grFactory = NULL; #endif - SkTDArray<const char*> matchStrs; if (!parse_flags_modulo(&moduloRemainder, &moduloDivisor) || !parse_flags_ignore_error_types(&gmmain.fIgnorableErrorTypes) || @@ -2154,7 +2146,6 @@ int tool_main(int argc, char** argv) { #endif !parse_flags_tile_grid_replay_scales(&tileGridReplayScales) || !parse_flags_resource_path() || - !parse_flags_match_strs(&matchStrs) || !parse_flags_jpeg_quality() || !parse_flags_configs(&configs, grFactory) || !parse_flags_pdf_rasterizers(configs, &pdfRasterizers) || @@ -2219,7 +2210,7 @@ int tool_main(int argc, char** argv) { const char* shortName = gm->shortName(); - if (SkCommandLineFlags::ShouldSkip(matchStrs, shortName)) { + if (SkCommandLineFlags::ShouldSkip(FLAGS_match, shortName)) { continue; } |