Merge "Fix falsing on notification dismissal." into tm-qpr-dev

This commit is contained in:
Dave Mankoff
2023-01-05 16:51:14 +00:00
committed by Android (Google) Code Review
2 changed files with 6 additions and 2 deletions

View File

@@ -69,6 +69,8 @@ public class TypeClassifier extends FalsingClassifier {
// A more sophisticated thing to do here would be to look at the size of the // A more sophisticated thing to do here would be to look at the size of the
// vertical change relative to the screen size. _Some_ amount of vertical // vertical change relative to the screen size. _Some_ amount of vertical
// change should be expected. // change should be expected.
wrongDirection = vertical;
break;
case NOTIFICATION_DISMISS: case NOTIFICATION_DISMISS:
wrongDirection = vertical; wrongDirection = vertical;
break; break;

View File

@@ -1902,8 +1902,10 @@ public class NotificationStackScrollLayoutController {
} }
if (ev.getActionMasked() == MotionEvent.ACTION_UP) { if (ev.getActionMasked() == MotionEvent.ACTION_UP) {
// Ensure the falsing manager records the touch. we don't do anything with it // Ensure the falsing manager records the touch. we don't do anything with it
// at the moment. // at the moment, but it may trigger a global falsing event.
mFalsingManager.isFalseTouch(Classifier.SHADE_DRAG); if (!horizontalSwipeWantsIt) {
mFalsingManager.isFalseTouch(Classifier.SHADE_DRAG);
}
mView.setCheckForLeaveBehind(true); mView.setCheckForLeaveBehind(true);
} }
traceJankOnTouchEvent(ev.getActionMasked(), scrollerWantsIt); traceJankOnTouchEvent(ev.getActionMasked(), scrollerWantsIt);