mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-02-18 10:18:20 +00:00
Cleaning up some animation states:
> When running one-off animations during quickstep, cancelling prevoisly running animations. > Cancelling such one-off animations when state is reset > Preventing touch proxied from recent transition to affect quickswitch (by affecting pagedView) Bug: 135686388 Bug: 135571566 Change-Id: Id647015a583761d8fd46a02e3e2d88027e282a79
This commit is contained in:
@@ -16,6 +16,7 @@
|
||||
|
||||
package com.android.launcher3;
|
||||
|
||||
import static com.android.launcher3.Utilities.shouldDisableGestures;
|
||||
import static com.android.launcher3.compat.AccessibilityManagerCompat.isAccessibilityEnabled;
|
||||
import static com.android.launcher3.compat.AccessibilityManagerCompat.isObservedEventType;
|
||||
import static com.android.launcher3.config.FeatureFlags.QUICKSTEP_SPRINGS;
|
||||
@@ -844,10 +845,11 @@ public abstract class PagedView<T extends View & PageIndicator> extends ViewGrou
|
||||
* If we return true, onTouchEvent will be called and we do the actual
|
||||
* scrolling there.
|
||||
*/
|
||||
acquireVelocityTrackerAndAddMovement(ev);
|
||||
|
||||
// Skip touch handling if there are no pages to swipe
|
||||
if (getChildCount() <= 0) return super.onInterceptTouchEvent(ev);
|
||||
if (getChildCount() <= 0 || shouldDisableGestures(ev)) return false;
|
||||
|
||||
acquireVelocityTrackerAndAddMovement(ev);
|
||||
|
||||
/*
|
||||
* Shortcut the most recurring case: the user is in the dragging
|
||||
@@ -1093,7 +1095,7 @@ public abstract class PagedView<T extends View & PageIndicator> extends ViewGrou
|
||||
@Override
|
||||
public boolean onTouchEvent(MotionEvent ev) {
|
||||
// Skip touch handling if there are no pages to swipe
|
||||
if (getChildCount() <= 0) return false;
|
||||
if (getChildCount() <= 0 || shouldDisableGestures(ev)) return false;
|
||||
|
||||
acquireVelocityTrackerAndAddMovement(ev);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user