Index: third_party/WebKit/Source/core/loader/resource/ImageResourceContent.h |
diff --git a/third_party/WebKit/Source/core/loader/resource/ImageResourceContent.h b/third_party/WebKit/Source/core/loader/resource/ImageResourceContent.h |
index 9d6417aebcf6c3fc086ed036a04aa9621fb8df54..e08180023cd7609a974a39f77b29a886c6ef2236 100644 |
--- a/third_party/WebKit/Source/core/loader/resource/ImageResourceContent.h |
+++ b/third_party/WebKit/Source/core/loader/resource/ImageResourceContent.h |
@@ -91,15 +91,19 @@ class CORE_EXPORT ImageResourceContent final |
DECLARE_TRACE(); |
- // Redirecting methods to Resource. |
- const KURL& url() const; |
- bool isAccessAllowed(SecurityOrigin*); |
- const ResourceResponse& response() const; |
+ // ResourceStatus and deriving predicates. |
+ // ImageResourceContent::getStatus() can be different from |
+ // ImageResource::getStatus(). Use ImageResourceContent::getStatus(). |
+ ResourceStatus getStatus() const; |
bool isLoaded() const; |
bool isLoading() const; |
bool errorOccurred() const; |
bool loadFailedOrCanceled() const; |
- ResourceStatus getStatus() const; |
+ |
+ // Redirecting methods to Resource. |
+ const KURL& url() const; |
+ bool isAccessAllowed(SecurityOrigin*); |
+ const ResourceResponse& response() const; |
const ResourceError& resourceError() const; |
// For FrameSerializer. |
@@ -140,9 +144,11 @@ class CORE_EXPORT ImageResourceContent final |
ShouldDecodeError, |
}; |
WARN_UNUSED_RESULT UpdateImageResult updateImage(PassRefPtr<SharedBuffer>, |
+ ResourceStatus, |
UpdateImageOption, |
bool allDataReceived); |
+ void notifyStartLoad(); |
void destroyDecodedData(); |
void doResetAnimation(); |
@@ -175,8 +181,10 @@ class CORE_EXPORT ImageResourceContent final |
// If not null, changeRect is the changed part of the image. |
void notifyObservers(NotifyFinishOption, const IntRect* changeRect = nullptr); |
void markObserverFinished(ImageResourceObserver*); |
+ void updateStatus(ResourceStatus, NotifyFinishOption); |
Member<ImageResourceInfo> m_info; |
+ ResourceStatus m_status = ResourceStatus::NotStarted; |
RefPtr<blink::Image> m_image; |