diff options
author | mtklein <mtklein@chromium.org> | 2015-01-09 10:06:39 -0800 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-01-09 10:06:40 -0800 |
commit | 72c9faab45124e08c85f70ca38536914862d947c (patch) | |
tree | 611893b84bb33b1592d058ee0f2382f7f86601b8 /include/core | |
parent | 4490da227f1475fb66af20532c14d6d9febd18b6 (diff) |
Fix up all the easy virtual ... SK_OVERRIDE cases.
This fixes every case where virtual and SK_OVERRIDE were on the same line,
which should be the bulk of cases. We'll have to manually clean up the rest
over time unless I level up in regexes.
for f in (find . -type f); perl -p -i -e 's/virtual (.*)SK_OVERRIDE/\1SK_OVERRIDE/g' $f; end
BUG=skia:
Review URL: https://codereview.chromium.org/806653007
Diffstat (limited to 'include/core')
-rw-r--r-- | include/core/SkBBHFactory.h | 2 | ||||
-rw-r--r-- | include/core/SkBitmap.h | 2 | ||||
-rw-r--r-- | include/core/SkBitmapDevice.h | 26 | ||||
-rw-r--r-- | include/core/SkComposeShader.h | 10 | ||||
-rw-r--r-- | include/core/SkFlattenable.h | 2 | ||||
-rw-r--r-- | include/core/SkImageFilter.h | 2 | ||||
-rw-r--r-- | include/core/SkMallocPixelRef.h | 6 | ||||
-rw-r--r-- | include/core/SkPathEffect.h | 2 | ||||
-rw-r--r-- | include/core/SkShader.h | 2 | ||||
-rw-r--r-- | include/core/SkStream.h | 90 | ||||
-rw-r--r-- | include/core/SkTypes.h | 2 | ||||
-rw-r--r-- | include/core/SkWeakRefCnt.h | 2 |
12 files changed, 74 insertions, 74 deletions
diff --git a/include/core/SkBBHFactory.h b/include/core/SkBBHFactory.h index 29c40ee951..490a6b5c07 100644 --- a/include/core/SkBBHFactory.h +++ b/include/core/SkBBHFactory.h @@ -24,7 +24,7 @@ public: class SK_API SkRTreeFactory : public SkBBHFactory { public: - virtual SkBBoxHierarchy* operator()(const SkRect& bounds) const SK_OVERRIDE; + SkBBoxHierarchy* operator()(const SkRect& bounds) const SK_OVERRIDE; private: typedef SkBBHFactory INHERITED; }; diff --git a/include/core/SkBitmap.h b/include/core/SkBitmap.h index ec0bffc90f..c28e3f53b2 100644 --- a/include/core/SkBitmap.h +++ b/include/core/SkBitmap.h @@ -694,7 +694,7 @@ public: */ class HeapAllocator : public Allocator { public: - virtual bool allocPixelRef(SkBitmap*, SkColorTable*) SK_OVERRIDE; + bool allocPixelRef(SkBitmap*, SkColorTable*) SK_OVERRIDE; }; class RLEPixels { diff --git a/include/core/SkBitmapDevice.h b/include/core/SkBitmapDevice.h index 03fd014d45..a801420584 100644 --- a/include/core/SkBitmapDevice.h +++ b/include/core/SkBitmapDevice.h @@ -35,7 +35,7 @@ public: return Create(info, NULL); } - virtual SkImageInfo imageInfo() const SK_OVERRIDE; + SkImageInfo imageInfo() const SK_OVERRIDE; protected: bool onShouldDisableLCD(const SkPaint&) const SK_OVERRIDE; @@ -45,7 +45,7 @@ protected: and are handling any looping from the paint, and any effects from the DrawFilter. */ - virtual void drawPaint(const SkDraw&, const SkPaint& paint) SK_OVERRIDE; + void drawPaint(const SkDraw&, const SkPaint& paint) SK_OVERRIDE; virtual void drawPoints(const SkDraw&, SkCanvas::PointMode mode, size_t count, const SkPoint[], const SkPaint& paint) SK_OVERRIDE; virtual void drawRect(const SkDraw&, const SkRect& r, @@ -114,7 +114,7 @@ protected: altered. The config/width/height/rowbytes must remain unchanged. @return the device contents as a bitmap */ - virtual const SkBitmap& onAccessBitmap() SK_OVERRIDE; + const SkBitmap& onAccessBitmap() SK_OVERRIDE; SkPixelRef* getPixelRef() const { return fBitmap.pixelRef(); } // just for subclasses, to assign a custom pixelref @@ -123,15 +123,15 @@ protected: return pr; } - virtual bool onReadPixels(const SkImageInfo&, void*, size_t, int x, int y) SK_OVERRIDE; - virtual bool onWritePixels(const SkImageInfo&, const void*, size_t, int, int) SK_OVERRIDE; - virtual void* onAccessPixels(SkImageInfo* info, size_t* rowBytes) SK_OVERRIDE; + bool onReadPixels(const SkImageInfo&, void*, size_t, int x, int y) SK_OVERRIDE; + bool onWritePixels(const SkImageInfo&, const void*, size_t, int, int) SK_OVERRIDE; + void* onAccessPixels(SkImageInfo* info, size_t* rowBytes) SK_OVERRIDE; /** Called when this device is installed into a Canvas. Balanced by a call to unlockPixels() when the device is removed from a Canvas. */ - virtual void lockPixels() SK_OVERRIDE; - virtual void unlockPixels() SK_OVERRIDE; + void lockPixels() SK_OVERRIDE; + void unlockPixels() SK_OVERRIDE; private: friend class SkCanvas; @@ -146,14 +146,14 @@ private: // used to change the backend's pixels (and possibly config/rowbytes) // but cannot change the width/height, so there should be no change to // any clip information. - virtual void replaceBitmapBackendForRasterSurface(const SkBitmap&) SK_OVERRIDE; + void replaceBitmapBackendForRasterSurface(const SkBitmap&) SK_OVERRIDE; - virtual SkBaseDevice* onCreateCompatibleDevice(const CreateInfo&) SK_OVERRIDE; + SkBaseDevice* onCreateCompatibleDevice(const CreateInfo&) SK_OVERRIDE; - virtual SkSurface* newSurface(const SkImageInfo&, const SkSurfaceProps&) SK_OVERRIDE; - virtual const void* peekPixels(SkImageInfo*, size_t* rowBytes) SK_OVERRIDE; + SkSurface* newSurface(const SkImageInfo&, const SkSurfaceProps&) SK_OVERRIDE; + const void* peekPixels(SkImageInfo*, size_t* rowBytes) SK_OVERRIDE; - virtual SkImageFilter::Cache* getImageFilterCache() SK_OVERRIDE; + SkImageFilter::Cache* getImageFilterCache() SK_OVERRIDE; SkBitmap fBitmap; diff --git a/include/core/SkComposeShader.h b/include/core/SkComposeShader.h index 3a28e1e03d..8e0d93f7e8 100644 --- a/include/core/SkComposeShader.h +++ b/include/core/SkComposeShader.h @@ -34,7 +34,7 @@ public: SkComposeShader(SkShader* sA, SkShader* sB, SkXfermode* mode = NULL); virtual ~SkComposeShader(); - virtual size_t contextSize() const SK_OVERRIDE; + size_t contextSize() const SK_OVERRIDE; class ComposeShaderContext : public SkShader::Context { public: @@ -48,7 +48,7 @@ public: virtual ~ComposeShaderContext(); - virtual void shadeSpan(int x, int y, SkPMColor[], int count) SK_OVERRIDE; + void shadeSpan(int x, int y, SkPMColor[], int count) SK_OVERRIDE; private: SkShader::Context* fShaderContextA; @@ -62,15 +62,15 @@ public: SkShader* getShaderB() { return fShaderB; } #endif - virtual bool asACompose(ComposeRec* rec) const SK_OVERRIDE; + bool asACompose(ComposeRec* rec) const SK_OVERRIDE; SK_TO_STRING_OVERRIDE() SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkComposeShader) protected: SkComposeShader(SkReadBuffer& ); - virtual void flatten(SkWriteBuffer&) const SK_OVERRIDE; - virtual Context* onCreateContext(const ContextRec&, void*) const SK_OVERRIDE; + void flatten(SkWriteBuffer&) const SK_OVERRIDE; + Context* onCreateContext(const ContextRec&, void*) const SK_OVERRIDE; private: SkShader* fShaderA; diff --git a/include/core/SkFlattenable.h b/include/core/SkFlattenable.h index e45627dbcc..1868176924 100644 --- a/include/core/SkFlattenable.h +++ b/include/core/SkFlattenable.h @@ -49,7 +49,7 @@ class SkWriteBuffer; static SkFlattenable* CreateProc(SkReadBuffer&); \ friend class SkPrivateEffectInitializer; \ public: \ - virtual Factory getFactory() const SK_OVERRIDE { return CreateProc; } + Factory getFactory() const SK_OVERRIDE { return CreateProc; } /** For SkFlattenable derived objects with a valid type This macro should only be used in base class objects in core diff --git a/include/core/SkImageFilter.h b/include/core/SkImageFilter.h index 42e2d7c33f..a65a24c3ee 100644 --- a/include/core/SkImageFilter.h +++ b/include/core/SkImageFilter.h @@ -242,7 +242,7 @@ protected: */ explicit SkImageFilter(int inputCount, SkReadBuffer& rb); - virtual void flatten(SkWriteBuffer&) const SK_OVERRIDE; + void flatten(SkWriteBuffer&) const SK_OVERRIDE; /** * This is the virtual which should be overridden by the derived class diff --git a/include/core/SkMallocPixelRef.h b/include/core/SkMallocPixelRef.h index 63ed19ae3c..259692da64 100644 --- a/include/core/SkMallocPixelRef.h +++ b/include/core/SkMallocPixelRef.h @@ -88,9 +88,9 @@ protected: bool ownPixels); virtual ~SkMallocPixelRef(); - virtual bool onNewLockPixels(LockRec*) SK_OVERRIDE; - virtual void onUnlockPixels() SK_OVERRIDE; - virtual size_t getAllocatedSizeInBytes() const SK_OVERRIDE; + bool onNewLockPixels(LockRec*) SK_OVERRIDE; + void onUnlockPixels() SK_OVERRIDE; + size_t getAllocatedSizeInBytes() const SK_OVERRIDE; private: void* fStorage; diff --git a/include/core/SkPathEffect.h b/include/core/SkPathEffect.h index 2a6e3a9c22..0675e97058 100644 --- a/include/core/SkPathEffect.h +++ b/include/core/SkPathEffect.h @@ -157,7 +157,7 @@ public: protected: SkPairPathEffect(SkPathEffect* pe0, SkPathEffect* pe1); - virtual void flatten(SkWriteBuffer&) const SK_OVERRIDE; + void flatten(SkWriteBuffer&) const SK_OVERRIDE; // these are visible to our subclasses SkPathEffect* fPE0, *fPE1; diff --git a/include/core/SkShader.h b/include/core/SkShader.h index 7cfb53619a..f8de276c7b 100644 --- a/include/core/SkShader.h +++ b/include/core/SkShader.h @@ -482,7 +482,7 @@ public: SK_DEFINE_FLATTENABLE_TYPE(SkShader) protected: - virtual void flatten(SkWriteBuffer&) const SK_OVERRIDE; + void flatten(SkWriteBuffer&) const SK_OVERRIDE; bool computeTotalInverse(const ContextRec&, SkMatrix* totalInverse) const; diff --git a/include/core/SkStream.h b/include/core/SkStream.h index 913286bdb4..2d5969853a 100644 --- a/include/core/SkStream.h +++ b/include/core/SkStream.h @@ -133,39 +133,39 @@ private: /** SkStreamRewindable is a SkStream for which rewind and duplicate are required. */ class SK_API SkStreamRewindable : public SkStream { public: - virtual bool rewind() SK_OVERRIDE = 0; - virtual SkStreamRewindable* duplicate() const SK_OVERRIDE = 0; + bool rewind() SK_OVERRIDE = 0; + SkStreamRewindable* duplicate() const SK_OVERRIDE = 0; }; /** SkStreamSeekable is a SkStreamRewindable for which position, seek, move, and fork are required. */ class SK_API SkStreamSeekable : public SkStreamRewindable { public: - virtual SkStreamSeekable* duplicate() const SK_OVERRIDE = 0; + SkStreamSeekable* duplicate() const SK_OVERRIDE = 0; - virtual bool hasPosition() const SK_OVERRIDE { return true; } - virtual size_t getPosition() const SK_OVERRIDE = 0; - virtual bool seek(size_t position) SK_OVERRIDE = 0; - virtual bool move(long offset) SK_OVERRIDE = 0; - virtual SkStreamSeekable* fork() const SK_OVERRIDE = 0; + bool hasPosition() const SK_OVERRIDE { return true; } + size_t getPosition() const SK_OVERRIDE = 0; + bool seek(size_t position) SK_OVERRIDE = 0; + bool move(long offset) SK_OVERRIDE = 0; + SkStreamSeekable* fork() const SK_OVERRIDE = 0; }; /** SkStreamAsset is a SkStreamSeekable for which getLength is required. */ class SK_API SkStreamAsset : public SkStreamSeekable { public: - virtual SkStreamAsset* duplicate() const SK_OVERRIDE = 0; - virtual SkStreamAsset* fork() const SK_OVERRIDE = 0; + SkStreamAsset* duplicate() const SK_OVERRIDE = 0; + SkStreamAsset* fork() const SK_OVERRIDE = 0; - virtual bool hasLength() const SK_OVERRIDE { return true; } - virtual size_t getLength() const SK_OVERRIDE = 0; + bool hasLength() const SK_OVERRIDE { return true; } + size_t getLength() const SK_OVERRIDE = 0; }; /** SkStreamMemory is a SkStreamAsset for which getMemoryBase is required. */ class SK_API SkStreamMemory : public SkStreamAsset { public: - virtual SkStreamMemory* duplicate() const SK_OVERRIDE = 0; - virtual SkStreamMemory* fork() const SK_OVERRIDE = 0; + SkStreamMemory* duplicate() const SK_OVERRIDE = 0; + SkStreamMemory* fork() const SK_OVERRIDE = 0; - virtual const void* getMemoryBase() SK_OVERRIDE = 0; + const void* getMemoryBase() SK_OVERRIDE = 0; }; class SK_API SkWStream : SkNoncopyable { @@ -248,20 +248,20 @@ public: */ void setPath(const char path[]); - virtual size_t read(void* buffer, size_t size) SK_OVERRIDE; - virtual bool isAtEnd() const SK_OVERRIDE; + size_t read(void* buffer, size_t size) SK_OVERRIDE; + bool isAtEnd() const SK_OVERRIDE; - virtual bool rewind() SK_OVERRIDE; - virtual SkStreamAsset* duplicate() const SK_OVERRIDE; + bool rewind() SK_OVERRIDE; + SkStreamAsset* duplicate() const SK_OVERRIDE; - virtual size_t getPosition() const SK_OVERRIDE; - virtual bool seek(size_t position) SK_OVERRIDE; - virtual bool move(long offset) SK_OVERRIDE; - virtual SkStreamAsset* fork() const SK_OVERRIDE; + size_t getPosition() const SK_OVERRIDE; + bool seek(size_t position) SK_OVERRIDE; + bool move(long offset) SK_OVERRIDE; + SkStreamAsset* fork() const SK_OVERRIDE; - virtual size_t getLength() const SK_OVERRIDE; + size_t getLength() const SK_OVERRIDE; - virtual const void* getMemoryBase() SK_OVERRIDE; + const void* getMemoryBase() SK_OVERRIDE; private: SkFILE* fFILE; @@ -320,20 +320,20 @@ public: const void* getAtPos(); size_t peek() const { return fOffset; } - virtual size_t read(void* buffer, size_t size) SK_OVERRIDE; - virtual bool isAtEnd() const SK_OVERRIDE; + size_t read(void* buffer, size_t size) SK_OVERRIDE; + bool isAtEnd() const SK_OVERRIDE; - virtual bool rewind() SK_OVERRIDE; - virtual SkMemoryStream* duplicate() const SK_OVERRIDE; + bool rewind() SK_OVERRIDE; + SkMemoryStream* duplicate() const SK_OVERRIDE; - virtual size_t getPosition() const SK_OVERRIDE; - virtual bool seek(size_t position) SK_OVERRIDE; - virtual bool move(long offset) SK_OVERRIDE; - virtual SkMemoryStream* fork() const SK_OVERRIDE; + size_t getPosition() const SK_OVERRIDE; + bool seek(size_t position) SK_OVERRIDE; + bool move(long offset) SK_OVERRIDE; + SkMemoryStream* fork() const SK_OVERRIDE; - virtual size_t getLength() const SK_OVERRIDE; + size_t getLength() const SK_OVERRIDE; - virtual const void* getMemoryBase() SK_OVERRIDE; + const void* getMemoryBase() SK_OVERRIDE; private: SkData* fData; @@ -355,9 +355,9 @@ public: */ bool isValid() const { return fFILE != NULL; } - virtual bool write(const void* buffer, size_t size) SK_OVERRIDE; - virtual void flush() SK_OVERRIDE; - virtual size_t bytesWritten() const SK_OVERRIDE; + bool write(const void* buffer, size_t size) SK_OVERRIDE; + void flush() SK_OVERRIDE; + size_t bytesWritten() const SK_OVERRIDE; private: SkFILE* fFILE; @@ -370,8 +370,8 @@ public: SK_DECLARE_INST_COUNT(SkMemoryWStream) SkMemoryWStream(void* buffer, size_t size); - virtual bool write(const void* buffer, size_t size) SK_OVERRIDE; - virtual size_t bytesWritten() const SK_OVERRIDE { return fBytesWritten; } + bool write(const void* buffer, size_t size) SK_OVERRIDE; + size_t bytesWritten() const SK_OVERRIDE { return fBytesWritten; } private: char* fBuffer; @@ -388,8 +388,8 @@ public: SkDynamicMemoryWStream(); virtual ~SkDynamicMemoryWStream(); - virtual bool write(const void* buffer, size_t size) SK_OVERRIDE; - virtual size_t bytesWritten() const SK_OVERRIDE { return fBytesWritten; } + bool write(const void* buffer, size_t size) SK_OVERRIDE; + size_t bytesWritten() const SK_OVERRIDE { return fBytesWritten; } // random access write // modifies stream and returns true if offset + size is less than or equal to getOffset() bool write(const void* buffer, size_t offset, size_t size); @@ -434,9 +434,9 @@ public: SK_DECLARE_INST_COUNT(SkDebugWStream) // overrides - virtual bool write(const void* buffer, size_t size) SK_OVERRIDE; - virtual void newline() SK_OVERRIDE; - virtual size_t bytesWritten() const SK_OVERRIDE { return fBytesWritten; } + bool write(const void* buffer, size_t size) SK_OVERRIDE; + void newline() SK_OVERRIDE; + size_t bytesWritten() const SK_OVERRIDE { return fBytesWritten; } private: size_t fBytesWritten; diff --git a/include/core/SkTypes.h b/include/core/SkTypes.h index 72ebb093c2..39923c59b7 100644 --- a/include/core/SkTypes.h +++ b/include/core/SkTypes.h @@ -138,7 +138,7 @@ inline void operator delete(void* p) { #define SK_TO_STRING_NONVIRT() void toString(SkString* str) const; #define SK_TO_STRING_VIRT() virtual void toString(SkString* str) const; #define SK_TO_STRING_PUREVIRT() virtual void toString(SkString* str) const = 0; - #define SK_TO_STRING_OVERRIDE() virtual void toString(SkString* str) const SK_OVERRIDE; + #define SK_TO_STRING_OVERRIDE() void toString(SkString* str) const SK_OVERRIDE; #endif template <bool> diff --git a/include/core/SkWeakRefCnt.h b/include/core/SkWeakRefCnt.h index 210dcc9f1c..3eb8ea5ca5 100644 --- a/include/core/SkWeakRefCnt.h +++ b/include/core/SkWeakRefCnt.h @@ -147,7 +147,7 @@ private: on the object and releases the implicit weak reference held collectively by the strong references. */ - virtual void internal_dispose() const SK_OVERRIDE { + void internal_dispose() const SK_OVERRIDE { weak_dispose(); weak_unref(); } |