Title: [137616] trunk/Source
- Revision
- 137616
- Author
- [email protected]
- Date
- 2012-12-13 10:52:58 -0800 (Thu, 13 Dec 2012)
Log Message
Check whether a touchDown lands on a registered touch event handler from the compositor
https://bugs.webkit.org/show_bug.cgi?id=104863
Patch by Yusuf Ozuysal <[email protected]> on 2012-12-13
Reviewed by James Robinson.
* src/WebCompositorInputHandlerImpl.cpp:
(WebKit::WebCompositorInputHandlerImpl::handleInputEventInternal):
Modified Paths
Diff
Modified: trunk/Source/Platform/chromium/public/WebInputHandlerClient.h (137615 => 137616)
--- trunk/Source/Platform/chromium/public/WebInputHandlerClient.h 2012-12-13 18:48:43 UTC (rev 137615)
+++ trunk/Source/Platform/chromium/public/WebInputHandlerClient.h 2012-12-13 18:52:58 UTC (rev 137616)
@@ -73,6 +73,10 @@
// Request another callback to WebInputHandler::animate().
virtual void scheduleAnimation() = 0;
+ // Returns whether there are any touch event handlers registered on the
+ // given WebPoint.
+ virtual bool haveTouchEventHandlersAt(WebPoint) = 0;
+
// Indicate that the final input event for the current vsync interval was received.
virtual void didReceiveLastInputEventForVSync() { }
Modified: trunk/Source/WebKit/chromium/ChangeLog (137615 => 137616)
--- trunk/Source/WebKit/chromium/ChangeLog 2012-12-13 18:48:43 UTC (rev 137615)
+++ trunk/Source/WebKit/chromium/ChangeLog 2012-12-13 18:52:58 UTC (rev 137616)
@@ -1,3 +1,13 @@
+2012-12-13 Yusuf Ozuysal <[email protected]>
+
+ Check whether a touchDown lands on a registered touch event handler from the compositor
+ https://bugs.webkit.org/show_bug.cgi?id=104863
+
+ Reviewed by James Robinson.
+
+ * src/WebCompositorInputHandlerImpl.cpp:
+ (WebKit::WebCompositorInputHandlerImpl::handleInputEventInternal):
+
2012-12-07 Levi Weintraub <[email protected]>
Add support for tracking hit test rectangles to enable fast event rejection in the compositor
Modified: trunk/Source/WebKit/chromium/src/WebCompositorInputHandlerImpl.cpp (137615 => 137616)
--- trunk/Source/WebKit/chromium/src/WebCompositorInputHandlerImpl.cpp 2012-12-13 18:48:43 UTC (rev 137615)
+++ trunk/Source/WebKit/chromium/src/WebCompositorInputHandlerImpl.cpp 2012-12-13 18:52:58 UTC (rev 137616)
@@ -198,6 +198,12 @@
} else if (event.type == WebInputEvent::GestureFlingCancel) {
if (cancelCurrentFling())
return DidHandle;
+#if ENABLE(TOUCH_EVENT_TRACKING)
+ } else if (event.type == WebInputEvent::TouchStart) {
+ const WebTouchEvent& touchEvent = *static_cast<const WebTouchEvent*>(&event);
+ if (!m_inputHandlerClient->haveTouchEventHandlersAt(touchEvent.touches[0].position))
+ return DropEvent;
+#endif
} else if (WebInputEvent::isKeyboardEventType(event.type)) {
cancelCurrentFling();
}
Modified: trunk/Source/WebKit/chromium/tests/WebCompositorInputHandlerImplTest.cpp (137615 => 137616)
--- trunk/Source/WebKit/chromium/tests/WebCompositorInputHandlerImplTest.cpp 2012-12-13 18:48:43 UTC (rev 137615)
+++ trunk/Source/WebKit/chromium/tests/WebCompositorInputHandlerImplTest.cpp 2012-12-13 18:52:58 UTC (rev 137616)
@@ -58,6 +58,8 @@
MOCK_METHOD0(scheduleAnimation, void());
+ MOCK_METHOD1(haveTouchEventHandlersAt, bool(WebPoint));
+
MOCK_METHOD2(scrollBegin, ScrollStatus(WebPoint, WebInputHandlerClient::ScrollInputType));
MOCK_METHOD2(scrollByIfPossible, bool(WebPoint, WebSize));
MOCK_METHOD0(scrollEnd, void());
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo/webkit-changes