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

Commit 08b2acf8 authored by Federico Baron's avatar Federico Baron Committed by Android (Google) Code Review
Browse files

Merge "Fix indexoutofbounds in Folder" into main

parents 3458141a 1f265cc9
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -800,6 +800,14 @@ public class Folder extends AbstractFloatingView implements ClipPathView, DragSo
            return;
        }

        int size = getIconsInReadingOrder().size();
        if (size <= 1) {
            Log.d(TAG, "Couldn't animate folder closed because there's " + size + " icons");
            closeComplete(false);
            post(this::announceAccessibilityChanges);
            return;
        }

        mContent.completePendingPageChanges();
        mContent.snapToPageImmediately(mContent.getDestinationPage());