Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(508)

Unified Diff: Source/core/html/HTMLImageElement.cpp

Issue 1112513005: Reload image bypassing the cache (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Using ExtraData Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/core/html/HTMLImageElement.cpp
diff --git a/Source/core/html/HTMLImageElement.cpp b/Source/core/html/HTMLImageElement.cpp
index a478b00d85924d81431dacbbcd778d30353579cf..56191bfd3d926c167a8f82b2b54fa311d44c67ef 100644
--- a/Source/core/html/HTMLImageElement.cpp
+++ b/Source/core/html/HTMLImageElement.cpp
@@ -638,6 +638,18 @@ float HTMLImageElement::sourceSize(Element& element)
return SizesAttributeParser(MediaValuesDynamic::create(document()), sizes).length();
}
+void HTMLImageElement::forceReload() const
+{
+ imageLoader().updateFromElement(ImageLoader::UpdateForcedReload);
+}
+
+const ResourceResponse& HTMLImageElement::getResponse() const
+{
+ if (imageLoader().image())
+ return imageLoader().image()->response();
+ return 0;
Nate Chapin 2015/05/05 22:03:49 Nit: ResourceResponse()
megjablon 2015/05/06 18:33:01 This can't be done because it's a local temporary
+}
+
void HTMLImageElement::selectSourceURL(ImageLoader::UpdateFromElementBehavior behavior)
{
if (!document().isActive())

Powered by Google App Engine
This is Rietveld 408576698