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

Commit eb885026 authored by Tony Wickham's avatar Tony Wickham
Browse files

Fix spring overscroll when there's a min scroll

Test: clear app recent apps, open Calculator, open Clock,
quick switch to Calculator and see no jump

Bug: 154815348
Change-Id: I6289d43efe5d850cb2fd807d15115c5ce38c16dd
parent bd49cea1
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -1068,7 +1068,7 @@ public abstract class PagedView<T extends View & PageIndicator> extends ViewGrou
    private int getSpringOverScroll(int amount) {
    private int getSpringOverScroll(int amount) {
        if (mScroller.isSpringing()) {
        if (mScroller.isSpringing()) {
            return amount < 0
            return amount < 0
                    ? mScroller.getCurrPos()
                    ? mScroller.getCurrPos() - mMinScroll
                    : Math.max(0, mScroller.getCurrPos() - mMaxScroll);
                    : Math.max(0, mScroller.getCurrPos() - mMaxScroll);
        } else {
        } else {
            return 0;
            return 0;