Bug 1016035 - Send MayStartSwipe event before sending the wheel event. r=kats
authorMarkus Stange <mstange@themasta.com>
Sat, 08 Aug 2015 18:31:58 -0400
changeset 259979 3705791032e1a61aa7f5ea5cb791e75f89e675e2
parent 259978 306cff29c09c90d559000fedb8dad9cfc3e182da
child 259980 487165622090635a02a62d7f42a5931af258f1eb
push id29296
push userryanvm@gmail.com
push dateSun, 30 Aug 2015 19:45:10 +0000
treeherdermozilla-central@2ad5077d86ba [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerskats
bugs1016035
milestone43.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1016035 - Send MayStartSwipe event before sending the wheel event. r=kats
widget/cocoa/nsChildView.mm
--- a/widget/cocoa/nsChildView.mm
+++ b/widget/cocoa/nsChildView.mm
@@ -2765,18 +2765,18 @@ nsChildView::DispatchAPZWheelInputEvent(
   }
 
   nsEventStatus status;
   switch(aEvent.mInputType) {
     case PANGESTURE_INPUT: {
       PanGestureInput panInput = aEvent.AsPanGestureInput();
       event = panInput.ToWidgetWheelEvent(this);
       if (aCanTriggerSwipe) {
+        SwipeInfo swipeInfo = SendMayStartSwipe(panInput);
         DispatchEvent(&event, status);
-        SwipeInfo swipeInfo = SendMayStartSwipe(panInput);
         if (swipeInfo.wantsSwipe &&
             IsPotentialSwipeStartEventOverscrollingViewport(event)) {
           TrackScrollEventAsSwipe(panInput, swipeInfo.allowedDirections);
         }
         return;
       }
       break;
     }