-
commit-queue@webkit.org authored
https://bugs.webkit.org/show_bug.cgi?id=96060 Patch by Rick Byers <rbyers@chromium.org> on 2012-09-17 Reviewed by Antonio Gomes. Adds GestureTapDownCancel as a new PlatformGestureEvent type. On ports that support gesture events, use GestureTapDown to trigger active/hover states, and GestureTap/GestureTapDownCancel to clear them. This is superior to using touch events for a number of reasons: 1) some ports (chromium) avoid sending touch events unless absolutely necessary, since they hurt scroll performance by blocking threaded scrolling. 2) with touch, and element really shouldn't be 'active' when the user happens to be touching it while scrolling. In that case they aren't 'manipulating the element', they're manipulating the page or div that is scrolling. 3) similarly, there may be other gestures that involve touching the element which aren't really about manipulating that element (eg. pinch to zoom). Test: fast/events/touch/gesture/gesture-tap-active-state.html Test: fast/events/touch/gesture/gesture-tap-active-state-iframe.html * dom/GestureEvent.cpp: (WebCore::GestureEvent::create): * page/EventHandler.cpp: (WebCore::EventHandler::handleGestureEvent): (WebCore::EventHandler::handleTouchEvent): * platform/PlatformEvent.h: Source/WebKit/chromium: Send GestureTapDownCancel to WebCore https://bugs.webkit.org/show_bug.cgi?id=96060 Patch by Rick Byers <rbyers@chromium.org> on 2012-09-17 Reviewed by Antonio Gomes. Plumb WebInputEvent::GetsureTapCancel to PlatformInputEvent::GestureTapDownCancel. After all the chromium code was landed, it was suggested that 'TapDownCancel' was a better name than 'TapCancel' since you can't cancel a Tap. I'm not changing the WebInputEvent definition here because that would be a breaking change to chromium, but I can do that as a series of follow-up CLs. * src/WebInputEventConversion.cpp: (WebKit::PlatformGestureEventBuilder::PlatformGestureEventBuilder): * src/WebPopupMenuImpl.cpp: (WebKit::WebPopupMenuImpl::handleInputEvent): * src/WebViewImpl.cpp: (WebKit::WebViewImpl::handleGestureEvent): Tools: Add handling of new GestureTapCancel in DRT https://bugs.webkit.org/show_bug.cgi?id=96183 Patch by Rick Byers <rbyers@chromium.org> on 2012-09-17 Reviewed by Antonio Gomes. * DumpRenderTree/chromium/TestWebPlugin.cpp: (TestWebPlugin::handleInputEvent): * DumpRenderTree/chromium/EventSender.cpp: (EventSender::gestureTapCancel): git-svn-id: http://svn.webkit.org/repository/webkit/trunk@128794 268f45cc-cd09-0410-ab3c-d52691b4dbfc
d87e5bae