summaryrefslogtreecommitdiffstats
path: root/skia/ext/pixel_ref_utils_unittest.cc
diff options
context:
space:
mode:
authordcheng <dcheng@chromium.org>2014-10-22 10:56:53 -0700
committerCommit bot <commit-bot@chromium.org>2014-10-22 17:57:23 +0000
commit9f927559a6cb793f8f4a23160a9b2df5254f4dba (patch)
treee9db28cb382ce56d71f97f576869c06011cbb90e /skia/ext/pixel_ref_utils_unittest.cc
parent45bd4345afae9ec2a8676b0a13c9dfbf58f8c32d (diff)
downloadchromium_src-9f927559a6cb793f8f4a23160a9b2df5254f4dba.zip
chromium_src-9f927559a6cb793f8f4a23160a9b2df5254f4dba.tar.gz
chromium_src-9f927559a6cb793f8f4a23160a9b2df5254f4dba.tar.bz2
Standardize usage of virtual/override/final in skia/
The Google C++ style guide states: Explicitly annotate overrides of virtual functions or virtual destructors with an override or (less frequently) final specifier. Older (pre-C++11) code will use the virtual keyword as an inferior alternative annotation. For clarity, use exactly one of override, final, or virtual when declaring an override. To better conform to these guidelines, the following constructs have been rewritten: - if a base class has a virtual destructor, then: virtual ~Foo(); -> ~Foo() override; - virtual void Foo() override; -> void Foo() override; - virtual void Foo() override final; -> void Foo() final; This patch was automatically generated. The clang plugin can generate fixit hints, which are suggested edits when it is 100% sure it knows how to fix a problem. The hints from the clang plugin were applied to the source tree using the tool in https://codereview.chromium.org/598073004. BUG=417463 R=junov@chromium.org Review URL: https://codereview.chromium.org/665373005 Cr-Commit-Position: refs/heads/master@{#300701}
Diffstat (limited to 'skia/ext/pixel_ref_utils_unittest.cc')
-rw-r--r--skia/ext/pixel_ref_utils_unittest.cc12
1 files changed, 5 insertions, 7 deletions
diff --git a/skia/ext/pixel_ref_utils_unittest.cc b/skia/ext/pixel_ref_utils_unittest.cc
index aef5766..656ef5c 100644
--- a/skia/ext/pixel_ref_utils_unittest.cc
+++ b/skia/ext/pixel_ref_utils_unittest.cc
@@ -34,20 +34,18 @@ class TestDiscardableShader : public SkShader {
CreateBitmap(gfx::Size(50, 50), "discardable", &bitmap_);
}
- virtual SkShader::BitmapType asABitmap(SkBitmap* bitmap,
- SkMatrix* matrix,
- TileMode xy[2]) const override {
+ SkShader::BitmapType asABitmap(SkBitmap* bitmap,
+ SkMatrix* matrix,
+ TileMode xy[2]) const override {
if (bitmap)
*bitmap = bitmap_;
return SkShader::kDefault_BitmapType;
}
// not indended to return an actual context. Just need to supply this.
- virtual size_t contextSize() const override {
- return sizeof(SkShader::Context);
- }
+ size_t contextSize() const override { return sizeof(SkShader::Context); }
- virtual void flatten(SkWriteBuffer&) const override {}
+ void flatten(SkWriteBuffer&) const override {}
SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(TestDiscardableShader);