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

Unified Diff: Source/web/WebViewImpl.cpp

Issue 1112513005: Reload image bypassing the cache (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 8 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/web/WebViewImpl.cpp
diff --git a/Source/web/WebViewImpl.cpp b/Source/web/WebViewImpl.cpp
index 870913bbd6e4a9e2bfee1a1f3deac1a83680c753..82371a278e565d2ce108616cf005b019ee68c3fa 100644
--- a/Source/web/WebViewImpl.cpp
+++ b/Source/web/WebViewImpl.cpp
@@ -3548,6 +3548,18 @@ void WebViewImpl::saveImageAt(const WebPoint& point)
m_client->saveImageFromDataURL(url);
}
+void WebViewImpl::reloadImageAt(const WebPoint& point, bool bypassCache)
+{
+ if (!m_page)
+ return;
+
+ HitTestResult result = hitTestResultForViewportPos(point);
Nate Chapin 2015/04/30 20:59:41 The need to do a hit test to re-find the element i
megjablon 2015/04/30 22:00:55 You you point me to the code for this? This follow
+ if (!isHTMLImageElement(result.innerNodeOrImageMapImage()) || result.absoluteImageURL().isEmpty())
+ return;
+
+ m_page->deprecatedLocalMainFrame()->editor().reloadImage(result, bypassCache);
+}
+
void WebViewImpl::dragSourceEndedAt(
const WebPoint& clientPoint,
const WebPoint& screenPoint,

Powered by Google App Engine
This is Rietveld 408576698