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

Unified Diff: third_party/WebKit/Source/platform/image-decoders/bmp/BMPImageReader.h

Issue 1493633004: Make platform/image-decoders to use USING_FAST_MALLOC. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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
Index: third_party/WebKit/Source/platform/image-decoders/bmp/BMPImageReader.h
diff --git a/third_party/WebKit/Source/platform/image-decoders/bmp/BMPImageReader.h b/third_party/WebKit/Source/platform/image-decoders/bmp/BMPImageReader.h
index c06a8d699944318a875ab252d69cc8192a491c70..7bfa563cae08989742d1172fecef682d9bd26b10 100644
--- a/third_party/WebKit/Source/platform/image-decoders/bmp/BMPImageReader.h
+++ b/third_party/WebKit/Source/platform/image-decoders/bmp/BMPImageReader.h
@@ -33,15 +33,18 @@
#include "platform/image-decoders/FastSharedBufferReader.h"
#include "platform/image-decoders/ImageDecoder.h"
+#include "wtf/Allocator.h"
#include "wtf/CPU.h"
+#include "wtf/Noncopyable.h"
#include <stdint.h>
namespace blink {
// This class decodes a BMP image. It is used in the BMP and ICO decoders,
// which wrap it in the appropriate code to read file headers, etc.
-class PLATFORM_EXPORT BMPImageReader {
+class PLATFORM_EXPORT BMPImageReader final {
USING_FAST_MALLOC(BMPImageReader);
+ WTF_MAKE_NONCOPYABLE(BMPImageReader);
public:
// Read a value from |buffer|, converting to an int assuming little
// endianness
@@ -106,6 +109,7 @@ private:
// These are based on the Windows BITMAPINFOHEADER and RGBTRIPLE
// structs, but with unnecessary entries removed.
struct BitmapInfoHeader {
+ DISALLOW_NEW();
uint32_t biSize;
int32_t biWidth;
int32_t biHeight;
@@ -114,6 +118,7 @@ private:
uint32_t biClrUsed;
};
struct RGBTriple {
+ DISALLOW_NEW_EXCEPT_PLACEMENT_NEW();
uint8_t rgbBlue;
uint8_t rgbGreen;
uint8_t rgbRed;

Powered by Google App Engine
This is Rietveld 408576698