| Index: tools/perf/measurements/screenshot.py
|
| diff --git a/tools/perf/measurements/screenshot.py b/tools/perf/measurements/screenshot.py
|
| index 5c4345a5a4ca397ed6c1f6b6d239f2da303d9081..8564c8a473236a06435c33aaef30ee18a4521a9e 100644
|
| --- a/tools/perf/measurements/screenshot.py
|
| +++ b/tools/perf/measurements/screenshot.py
|
| @@ -9,11 +9,21 @@
|
|
|
|
|
| class Screenshot(page_test.PageTest):
|
| - def __init__(self, png_outdir):
|
| + def __init__(self):
|
| super(Screenshot, self).__init__(
|
| action_name_to_run = 'RunPageInteractions',
|
| is_action_name_to_run_optional=True)
|
| - self._png_outdir = png_outdir
|
| +
|
| + @classmethod
|
| + def AddCommandLineArgs(cls, parser):
|
| + parser.add_option('--png-outdir',
|
| + help='Output directory for the PNG files')
|
| +
|
| + @classmethod
|
| + def ProcessCommandLineArgs(cls, parser, args):
|
| + if not args.png_outdir:
|
| + parser.error('Please specify --png-outdir')
|
| + cls._png_outdir = args.png_outdir
|
|
|
| def ValidateAndMeasurePage(self, page, tab, results):
|
| if not tab.screenshot_supported:
|
|
|