Index: third_party/WebKit/Source/core/loader/FrameLoader.cpp |
diff --git a/third_party/WebKit/Source/core/loader/FrameLoader.cpp b/third_party/WebKit/Source/core/loader/FrameLoader.cpp |
index 24a3de0448d89de15982ca00c20cb04bc10d9624..1668aa80c56fac17ba9a3b6a9fe03e8523409b54 100644 |
--- a/third_party/WebKit/Source/core/loader/FrameLoader.cpp |
+++ b/third_party/WebKit/Source/core/loader/FrameLoader.cpp |
@@ -1343,20 +1343,14 @@ |
if (!prepareForCommit()) |
return; |
- // If we are loading the mainframe, or a frame that is a local root, it is |
- // important to explicitly set the event listenener properties to Nothing as |
- // this triggers notifications to the client. Clients may assume the presence |
- // of handlers for touch and wheel events, so these notifications tell it |
- // there are (presently) no handlers. |
- if (m_frame->isLocalRoot()) { |
+ if (isLoadingMainFrame()) { |
m_frame->page()->chromeClient().setEventListenerProperties( |
- m_frame, WebEventListenerClass::TouchStartOrMove, |
+ WebEventListenerClass::TouchStartOrMove, |
WebEventListenerProperties::Nothing); |
m_frame->page()->chromeClient().setEventListenerProperties( |
- m_frame, WebEventListenerClass::MouseWheel, |
- WebEventListenerProperties::Nothing); |
+ WebEventListenerClass::MouseWheel, WebEventListenerProperties::Nothing); |
m_frame->page()->chromeClient().setEventListenerProperties( |
- m_frame, WebEventListenerClass::TouchEndOrCancel, |
+ WebEventListenerClass::TouchEndOrCancel, |
WebEventListenerProperties::Nothing); |
} |