Index: Source/core/platform/graphics/BitmapImage.h |
diff --git a/Source/core/platform/graphics/BitmapImage.h b/Source/core/platform/graphics/BitmapImage.h |
index f4f17b28439bf079e592db8265c9d2a606f0c57b..d3906c9d4c11fc83facb02c624ae965b3d4b58b2 100644 |
--- a/Source/core/platform/graphics/BitmapImage.h |
+++ b/Source/core/platform/graphics/BitmapImage.h |
@@ -166,22 +166,18 @@ protected: |
// Called before accessing m_frames[index]. Returns false on index out of bounds. |
bool ensureFrameIsCached(size_t index); |
- // Called to invalidate cached data. When |destroyAll| is true, we wipe out |
- // the entire frame buffer cache and tell the image source to destroy |
- // everything; this is used when e.g. we want to free some room in the image |
- // cache. If |destroyAll| is false, we only delete frames up to the current |
- // one; this is used while animating large images to keep memory footprint |
- // low without redecoding the whole image on every frame. |
- virtual void destroyDecodedData(bool destroyAll = true); |
- |
- // If the image is large enough, calls destroyDecodedData() and passes |
- // |destroyAll| along. |
- void destroyDecodedDataIfNecessary(bool destroyAll); |
+ // Called to invalidate cached data. This is used while animating large |
+ // images to keep memory footprint low. The decoder may preserve some frames |
+ // to avoid redecoding the whole image on every frame. |
+ virtual void destroyDecodedData() OVERRIDE; |
Peter Kasting
2013/05/29 02:02:18
Nit: I'm a big fan of OVERRIDE, but if we're addin
Xianzhu
2013/05/29 18:37:01
Done.
|
+ |
+ // If the image is large enough, calls destroyDecodedData(). |
+ void destroyDecodedDataIfNecessary(); |
// Generally called by destroyDecodedData(), destroys whole-image metadata |
// and notifies observers that the memory footprint has (hopefully) |
// decreased by |frameBytesCleared|. |
- void destroyMetadataAndNotify(unsigned frameBytesCleared); |
+ void destroyMetadataAndNotify(size_t frameBytesCleared); |
// Whether or not size is available yet. |
bool isSizeAvailable(); |