Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit faaa3654 authored by Jim Miller's avatar Jim Miller
Browse files

Fix possible crash in System UI

Fixes bug 11215581

Change-Id: Ic76ad783729316539e8e57feb098d6e823b4ecdf
parent 1680cfd8
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -1553,6 +1553,9 @@ public abstract class PagedView extends ViewGroup implements ViewGroup.OnHierarc
            if (mTouchState == TOUCH_STATE_SCROLLING) {
                final int activePointerId = mActivePointerId;
                final int pointerIndex = ev.findPointerIndex(activePointerId);

                if (pointerIndex == -1) return true;

                final float x = ev.getX(pointerIndex);
                final VelocityTracker velocityTracker = mVelocityTracker;
                velocityTracker.computeCurrentVelocity(1000, mMaximumVelocity);