diff options
Diffstat (limited to 'WebCore/platform/image-decoders/ico')
-rw-r--r-- | WebCore/platform/image-decoders/ico/ICOImageDecoder.cpp | 9 | ||||
-rw-r--r-- | WebCore/platform/image-decoders/ico/ICOImageDecoder.h | 2 |
2 files changed, 7 insertions, 4 deletions
diff --git a/WebCore/platform/image-decoders/ico/ICOImageDecoder.cpp b/WebCore/platform/image-decoders/ico/ICOImageDecoder.cpp index b07cf92..92a7dcf 100644 --- a/WebCore/platform/image-decoders/ico/ICOImageDecoder.cpp +++ b/WebCore/platform/image-decoders/ico/ICOImageDecoder.cpp @@ -44,8 +44,9 @@ namespace WebCore { static const size_t sizeOfDirectory = 6; static const size_t sizeOfDirEntry = 16; -ICOImageDecoder::ICOImageDecoder(bool premultiplyAlpha, bool ignoreGammaAndColorProfile) - : ImageDecoder(premultiplyAlpha, ignoreGammaAndColorProfile) +ICOImageDecoder::ICOImageDecoder(ImageSource::AlphaOption alphaOption, + ImageSource::GammaAndColorProfileOption gammaAndColorProfileOption) + : ImageDecoder(alphaOption, gammaAndColorProfileOption) , m_decodedOffset(0) { } @@ -201,7 +202,9 @@ bool ICOImageDecoder::decodeAtIndex(size_t index) } if (!m_pngDecoders[index]) { - m_pngDecoders[index].set(new PNGImageDecoder(m_premultiplyAlpha, m_ignoreGammaAndColorProfile)); + m_pngDecoders[index].set( + new PNGImageDecoder(m_premultiplyAlpha ? ImageSource::AlphaPremultiplied : ImageSource::AlphaNotPremultiplied, + m_ignoreGammaAndColorProfile ? ImageSource::GammaAndColorProfileIgnored : ImageSource::GammaAndColorProfileApplied)); setDataForPNGDecoderAtIndex(index); } // Fail if the size the PNGImageDecoder calculated does not match the size diff --git a/WebCore/platform/image-decoders/ico/ICOImageDecoder.h b/WebCore/platform/image-decoders/ico/ICOImageDecoder.h index dc631f4..c2af6a3 100644 --- a/WebCore/platform/image-decoders/ico/ICOImageDecoder.h +++ b/WebCore/platform/image-decoders/ico/ICOImageDecoder.h @@ -40,7 +40,7 @@ namespace WebCore { // This class decodes the ICO and CUR image formats. class ICOImageDecoder : public ImageDecoder { public: - ICOImageDecoder(bool premultiplyAlpha, bool ignoreGammaAndColorProfile); + ICOImageDecoder(ImageSource::AlphaOption, ImageSource::GammaAndColorProfileOption); virtual ~ICOImageDecoder(); // ImageDecoder |