summaryrefslogtreecommitdiff
path: root/Source/WebCore/dom/MouseEvent.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Source/WebCore/dom/MouseEvent.cpp')
-rw-r--r--Source/WebCore/dom/MouseEvent.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/Source/WebCore/dom/MouseEvent.cpp b/Source/WebCore/dom/MouseEvent.cpp
index c3689c6dd..cf2e2660a 100644
--- a/Source/WebCore/dom/MouseEvent.cpp
+++ b/Source/WebCore/dom/MouseEvent.cpp
@@ -201,8 +201,8 @@ bool MouseEventDispatchMediator::dispatchEvent(EventDispatcher* dispatcher) cons
if (event()->type().isEmpty())
return false; // Shouldn't happen.
- RefPtr<EventTarget> relatedTarget = dispatcher->adjustRelatedTarget(event(), event()->relatedTarget());
- event()->setRelatedTarget(relatedTarget);
+ EventTarget* relatedTarget = event()->relatedTarget();
+ dispatcher->adjustRelatedTarget(event(), relatedTarget);
dispatcher->dispatchEvent(event());
bool swallowEvent = event()->defaultHandled() || event()->defaultPrevented();