Bug 1041471 - Call CancelAnimation() on a touch-cancel. r=kats
authorBotond Ballo <botond@mozilla.com>
Mon, 21 Jul 2014 15:42:58 -0400
changeset 195542 abe6b92d330b741b34aa28fea5a2cfe101255faf
parent 195541 c1ea5a8280d7bda0cd827ff926da650ff2038e03
child 195543 9bc64b0290c28723ce8db343bd7f48972e7ff289
push id46620
push userbballo@mozilla.com
push dateTue, 22 Jul 2014 20:50:56 +0000
treeherdermozilla-inbound@9bc64b0290c2 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerskats
bugs1041471
milestone34.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 1041471 - Call CancelAnimation() on a touch-cancel. r=kats
gfx/layers/apz/src/AsyncPanZoomController.cpp
--- a/gfx/layers/apz/src/AsyncPanZoomController.cpp
+++ b/gfx/layers/apz/src/AsyncPanZoomController.cpp
@@ -1142,17 +1142,17 @@ nsEventStatus AsyncPanZoomController::On
   }
 
   return nsEventStatus_eConsumeNoDefault;
 }
 
 nsEventStatus AsyncPanZoomController::OnTouchCancel(const MultiTouchInput& aEvent) {
   APZC_LOG("%p got a touch-cancel in state %d\n", this, mState);
   OnTouchEndOrCancel();
-  SetState(NOTHING);
+  CancelAnimation();
   return nsEventStatus_eConsumeNoDefault;
 }
 
 nsEventStatus AsyncPanZoomController::OnScaleBegin(const PinchGestureInput& aEvent) {
   APZC_LOG("%p got a scale-begin in state %d\n", this, mState);
 
   // Note that there may not be a touch block at this point, if we received the
   // PinchGestureEvent directly from widget code without any touch events.