Index: third_party/WebKit/Source/core/fetch/ImageResource.h |
diff --git a/third_party/WebKit/Source/core/fetch/ImageResource.h b/third_party/WebKit/Source/core/fetch/ImageResource.h |
index 3a7c81076e9667e8cca6b2d7a17227acad038e0f..64f6acfd34405ffee16048ddbfa3eb868343be4d 100644 |
--- a/third_party/WebKit/Source/core/fetch/ImageResource.h |
+++ b/third_party/WebKit/Source/core/fetch/ImageResource.h |
@@ -160,6 +160,10 @@ class CORE_EXPORT ImageResource final |
return m_isPlaceholder && willPaintBrokenImage(); |
} |
+ void setNotRefetchableDataFromDiskCache() { |
+ m_isRefetchableDataFromDiskCache = false; |
+ } |
+ |
DECLARE_VIRTUAL_TRACE(); |
private: |
@@ -224,6 +228,10 @@ class CORE_EXPORT ImageResource final |
Timer<ImageResource> m_flushTimer; |
double m_lastFlushTime = 0.; |
Image::SizeAvailability m_sizeAvailable = Image::SizeUnavailable; |
+ |
+ // Indicates if this resource's encoded image data can be purged and refetched |
+ // from disk cache to save memory usage. See crbug/664437. |
+ bool m_isRefetchableDataFromDiskCache; |
}; |
DEFINE_RESOURCE_TYPE_CASTS(Image); |