Index: Source/core/editing/Editor.cpp |
diff --git a/Source/core/editing/Editor.cpp b/Source/core/editing/Editor.cpp |
index 7876e20081b96f5bb283b83733b6fe813e3dfa2c..2c56af45943c93565479e5f8e3b8b3346ef5b64a 100644 |
--- a/Source/core/editing/Editor.cpp |
+++ b/Source/core/editing/Editor.cpp |
@@ -463,6 +463,15 @@ static void writeImageNodeToPasteboard(Pasteboard* pasteboard, Node* node, const |
pasteboard->writeImage(image.get(), url, title); |
} |
+static void reloadImageNode(Node* node, bool bypassCache) |
+{ |
+ ASSERT(node); |
+ if (isHTMLImageElement(*node)) { |
+ HTMLImageElement& element = toHTMLImageElement(*node); |
+ element.imageLoader().updateFromElement(ImageLoader::UpdateIgnorePreviousError, bypassCache); |
+ } |
+} |
+ |
// Returns whether caller should continue with "the default processing", which is the same as |
// the event handler NOT setting the return value to false |
bool Editor::dispatchCPPEvent(const AtomicString& eventType, DataTransferAccessPolicy policy, PasteMode pasteMode) |
@@ -961,6 +970,11 @@ void Editor::copyImage(const HitTestResult& result) |
writeImageNodeToPasteboard(Pasteboard::generalPasteboard(), result.innerNodeOrImageMapImage(), result.altDisplayString()); |
} |
+void Editor::reloadImage(const HitTestResult& result, bool bypassCache) |
Nate Chapin
2015/04/30 20:59:41
This doesn't really have anything to do with Edito
megjablon
2015/04/30 22:00:54
Do you have any ideas for an alternate path? I was
|
+{ |
+ reloadImageNode(result.innerNodeOrImageMapImage(), bypassCache); |
+} |
+ |
bool Editor::canUndo() |
{ |
if (UndoStack* undoStack = this->undoStack()) |