Chromium Code Reviews| Index: third_party/WebKit/Source/platform/image-decoders/ico/ICOImageDecoder.h |
| diff --git a/third_party/WebKit/Source/platform/image-decoders/ico/ICOImageDecoder.h b/third_party/WebKit/Source/platform/image-decoders/ico/ICOImageDecoder.h |
| index 0f875ffe6328a0940408ba4756d2c8053ba522f9..c4e91b0d1d511feec5ab062f33c2891c82d9ad31 100644 |
| --- a/third_party/WebKit/Source/platform/image-decoders/ico/ICOImageDecoder.h |
| +++ b/third_party/WebKit/Source/platform/image-decoders/ico/ICOImageDecoder.h |
| @@ -41,6 +41,7 @@ class PNGImageDecoder; |
| // This class decodes the ICO and CUR image formats. |
| class PLATFORM_EXPORT ICOImageDecoder final : public ImageDecoder { |
| + WTF_MAKE_NONCOPYABLE(ICOImageDecoder); |
|
scroggo_chromium
2016/06/24 21:36:24
Weird that this wasn't here before...
|
| public: |
| ICOImageDecoder(AlphaOption, GammaAndColorProfileOption, size_t maxDecodedBytes); |
| ~ICOImageDecoder() override; |
| @@ -84,7 +85,7 @@ private: |
| static bool compareEntries(const IconDirectoryEntry& a, const IconDirectoryEntry& b); |
| // ImageDecoder: |
| - virtual void decodeSize() { decode(0, true); } |
| + void decodeSize() override { decode(0, true); } |
| size_t decodeFrameCount() override; |
| void decode(size_t index) override { decode(index, false); } |
| @@ -159,6 +160,11 @@ private: |
| typedef Vector<IconDirectoryEntry> IconDirectoryEntries; |
| IconDirectoryEntries m_dirEntries; |
| + // Count of directory entries is parsed from header before initializing |
| + // m_dirEntries. m_dirEntries is populated only when full header |
| + // information including directory entries is available. |
| + size_t m_dirEntriesCount; |
| + |
| // The image decoders for the various frames. |
| typedef Vector<std::unique_ptr<BMPImageReader>> BMPReaders; |
| BMPReaders m_bmpReaders; |