Title: [146378] trunk/Source
Revision
146378
Author
commit-qu...@webkit.org
Date
2013-03-20 12:27:19 -0700 (Wed, 20 Mar 2013)

Log Message

Remove PlatformEvent::GestureDoubleTap
https://bugs.webkit.org/show_bug.cgi?id=93045

Patch by Yufeng Shen <mile...@chromium.org> on 2013-03-20
Reviewed by Antonio Gomes.

Source/WebCore:

PlatformEvent::GestureDoubleTap is not currently
used in WebCore and replaced by GestureTap with
tap count 2, so remove it.

Test: We are removing something that is not used, so
no new test. All existing tests pass.

* dom/GestureEvent.cpp:
(WebCore::GestureEvent::create):
* page/EventHandler.cpp:
(WebCore::EventHandler::handleGestureEvent):
* platform/PlatformEvent.h:
* platform/chromium/PopupContainer.cpp:
(WebCore::PopupContainer::handleGestureEvent):

Source/WebKit/chromium:

PlatformEvent::GestureDoubleTap is not currently
used in WebCore so remove it.

* src/WebInputEventConversion.cpp:
(WebKit::PlatformGestureEventBuilder::PlatformGestureEventBuilder):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (146377 => 146378)


--- trunk/Source/WebCore/ChangeLog	2013-03-20 19:22:17 UTC (rev 146377)
+++ trunk/Source/WebCore/ChangeLog	2013-03-20 19:27:19 UTC (rev 146378)
@@ -1,3 +1,25 @@
+2013-03-20  Yufeng Shen  <mile...@chromium.org>
+
+        Remove PlatformEvent::GestureDoubleTap
+        https://bugs.webkit.org/show_bug.cgi?id=93045
+
+        Reviewed by Antonio Gomes.
+
+        PlatformEvent::GestureDoubleTap is not currently
+        used in WebCore and replaced by GestureTap with
+        tap count 2, so remove it.
+
+        Test: We are removing something that is not used, so
+        no new test. All existing tests pass.
+
+        * dom/GestureEvent.cpp:
+        (WebCore::GestureEvent::create):
+        * page/EventHandler.cpp:
+        (WebCore::EventHandler::handleGestureEvent):
+        * platform/PlatformEvent.h:
+        * platform/chromium/PopupContainer.cpp:
+        (WebCore::PopupContainer::handleGestureEvent):
+
 2013-03-20  Ojan Vafai  <o...@chromium.org>
 
         Move repaint methods from RenderObject to RenderBox

Modified: trunk/Source/WebCore/dom/GestureEvent.cpp (146377 => 146378)


--- trunk/Source/WebCore/dom/GestureEvent.cpp	2013-03-20 19:22:17 UTC (rev 146377)
+++ trunk/Source/WebCore/dom/GestureEvent.cpp	2013-03-20 19:27:19 UTC (rev 146378)
@@ -53,7 +53,6 @@
         eventType = eventNames().gesturetapEvent; break;
     case PlatformEvent::GestureTapDown:
         eventType = eventNames().gesturetapdownEvent; break;
-    case PlatformEvent::GestureDoubleTap:
     case PlatformEvent::GestureTwoFingerTap:
     case PlatformEvent::GestureLongPress:
     case PlatformEvent::GesturePinchBegin:

Modified: trunk/Source/WebCore/page/EventHandler.cpp (146377 => 146378)


--- trunk/Source/WebCore/page/EventHandler.cpp	2013-03-20 19:22:17 UTC (rev 146377)
+++ trunk/Source/WebCore/page/EventHandler.cpp	2013-03-20 19:27:19 UTC (rev 146378)
@@ -2454,11 +2454,6 @@
 
 bool EventHandler::handleGestureEvent(const PlatformGestureEvent& gestureEvent)
 {
-    // We don't use DoubleTap at the moment, it's mostly redundant with tap since tap now contains
-    // a tap count. FIXME: We should probably remove GestureDoubleTap (http://wkb.ug/93045).
-    if (gestureEvent.type() == PlatformEvent::GestureDoubleTap)
-        return false;
-
     Node* eventTarget = 0;
     Scrollbar* scrollbar = 0;
     if (gestureEvent.type() == PlatformEvent::GestureScrollEnd
@@ -2545,7 +2540,6 @@
         return handleGestureLongTap(gestureEvent);
     case PlatformEvent::GestureTwoFingerTap:
         return handleGestureTwoFingerTap(gestureEvent);
-    case PlatformEvent::GestureDoubleTap:
     case PlatformEvent::GesturePinchBegin:
     case PlatformEvent::GesturePinchEnd:
     case PlatformEvent::GesturePinchUpdate:

Modified: trunk/Source/WebCore/platform/PlatformEvent.h (146377 => 146378)


--- trunk/Source/WebCore/platform/PlatformEvent.h	2013-03-20 19:22:17 UTC (rev 146377)
+++ trunk/Source/WebCore/platform/PlatformEvent.h	2013-03-20 19:27:19 UTC (rev 146378)
@@ -56,7 +56,6 @@
         GestureTap,
         GestureTapDown,
         GestureTapDownCancel,
-        GestureDoubleTap,
         GestureTwoFingerTap,
         GestureLongPress,
         GestureLongTap,

Modified: trunk/Source/WebCore/platform/chromium/PopupContainer.cpp (146377 => 146378)


--- trunk/Source/WebCore/platform/chromium/PopupContainer.cpp	2013-03-20 19:22:17 UTC (rev 146377)
+++ trunk/Source/WebCore/platform/chromium/PopupContainer.cpp	2013-03-20 19:27:19 UTC (rev 146378)
@@ -319,8 +319,6 @@
         handleMouseReleaseEvent(fakeMouseUp);
         return true;
     }
-    case PlatformEvent::GestureDoubleTap:
-        break;
     case PlatformEvent::GestureScrollUpdate:
     case PlatformEvent::GestureScrollUpdateWithoutPropagation: {
         PlatformWheelEvent syntheticWheelEvent(gestureEvent.position(), gestureEvent.globalPosition(), gestureEvent.deltaX(), gestureEvent.deltaY(), gestureEvent.deltaX() / 120.0f, gestureEvent.deltaY() / 120.0f, ScrollByPixelWheelEvent, gestureEvent.shiftKey(), gestureEvent.ctrlKey(), gestureEvent.altKey(), gestureEvent.metaKey());

Modified: trunk/Source/WebKit/chromium/ChangeLog (146377 => 146378)


--- trunk/Source/WebKit/chromium/ChangeLog	2013-03-20 19:22:17 UTC (rev 146377)
+++ trunk/Source/WebKit/chromium/ChangeLog	2013-03-20 19:27:19 UTC (rev 146378)
@@ -1,3 +1,16 @@
+2013-03-20  Yufeng Shen  <mile...@chromium.org>
+
+        Remove PlatformEvent::GestureDoubleTap
+        https://bugs.webkit.org/show_bug.cgi?id=93045
+
+        Reviewed by Antonio Gomes.
+
+        PlatformEvent::GestureDoubleTap is not currently
+        used in WebCore so remove it.
+
+        * src/WebInputEventConversion.cpp:
+        (WebKit::PlatformGestureEventBuilder::PlatformGestureEventBuilder):
+
 2013-03-20  Justin Novosad  <ju...@google.com>
 
         [Chromium] Code cleanup: removing support for non-deferred 2d canvas rendering

Modified: trunk/Source/WebKit/chromium/src/WebInputEventConversion.cpp (146377 => 146378)


--- trunk/Source/WebKit/chromium/src/WebInputEventConversion.cpp	2013-03-20 19:22:17 UTC (rev 146377)
+++ trunk/Source/WebKit/chromium/src/WebInputEventConversion.cpp	2013-03-20 19:27:19 UTC (rev 146378)
@@ -186,9 +186,6 @@
     case WebInputEvent::GestureTapCancel:
         m_type = PlatformEvent::GestureTapDownCancel;
         break;
-    case WebInputEvent::GestureDoubleTap:
-        m_type = PlatformEvent::GestureDoubleTap;
-        break;
     case WebInputEvent::GestureTwoFingerTap:
         m_type = PlatformEvent::GestureTwoFingerTap;
         m_area = expandedIntSize(FloatSize(e.data.twoFingerTap.firstFingerWidth / scale, e.data.twoFingerTap.firstFingerHeight / scale));

Modified: trunk/Source/WebKit/chromium/src/WebViewImpl.cpp (146377 => 146378)


--- trunk/Source/WebKit/chromium/src/WebViewImpl.cpp	2013-03-20 19:22:17 UTC (rev 146377)
+++ trunk/Source/WebKit/chromium/src/WebViewImpl.cpp	2013-03-20 19:27:19 UTC (rev 146378)
@@ -827,9 +827,11 @@
         if (m_webSettings->doubleTapToZoomEnabled() && m_minimumPageScaleFactor != m_maximumPageScaleFactor) {
             m_client->cancelScheduledContentIntents();
             animateZoomAroundPoint(platformEvent.position(), DoubleTap);
-            eventSwallowed = true;
-            break;
         }
+        // GestureDoubleTap is currently only used by Android for zooming. For WebCore,
+        // GestureTap with tap count = 2 is used instead. So we drop GestureDoubleTap here.
+        eventSwallowed = true;
+        break;
     case WebInputEvent::GestureScrollBegin:
     case WebInputEvent::GesturePinchBegin:
         m_client->cancelScheduledContentIntents();
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to