Index: Source/core/page/EventHandler.cpp |
diff --git a/Source/core/page/EventHandler.cpp b/Source/core/page/EventHandler.cpp |
index e6b1d96267fa3ba247d397aee8df842608c2fe77..6b685a635c5ecdaa34095c5141989f33258e4f6c 100644 |
--- a/Source/core/page/EventHandler.cpp |
+++ b/Source/core/page/EventHandler.cpp |
@@ -51,6 +51,7 @@ |
#include "core/events/TouchEvent.h" |
#include "core/events/WheelEvent.h" |
#include "core/fetch/ImageResource.h" |
+#include "core/frame/EventHandlerRegistry.h" |
#include "core/frame/FrameView.h" |
#include "core/frame/LocalFrame.h" |
#include "core/html/HTMLDialogElement.h" |
@@ -3494,7 +3495,7 @@ bool EventHandler::handleTouchEvent(const PlatformTouchEvent& event) |
// If there's no document receiving touch events, or no handlers on the |
// document set to receive the events, then we can skip all the rest of |
// this work. |
- if (!m_touchSequenceDocument || !m_touchSequenceDocument->hasTouchEventHandlers() || !m_touchSequenceDocument->frame()) { |
+ if (!m_touchSequenceDocument || !m_touchSequenceDocument->frameHost() || !m_touchSequenceDocument->frameHost()->eventHandlerRegistry().hasEventHandlers(EventHandlerRegistry::TouchEvent) || !m_touchSequenceDocument->frame()) { |
if (allTouchReleased) { |
m_touchSequenceDocument.clear(); |
m_touchSequenceUserGestureToken.clear(); |