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

Commit 9b1bb81f authored by Romain Guy's avatar Romain Guy
Browse files

Do not detach headers and footers from the list view.

parent b5e15690
Loading
Loading
Loading
Loading
+7 −3
Original line number Diff line number Diff line
@@ -4224,7 +4224,9 @@ public abstract class AbsListView extends AdapterView<ListAdapter> implements Te
            // into the scrap heap
            int viewType = lp.viewType;
            if (!shouldRecycleViewType(viewType)) {
                if (viewType != ITEM_VIEW_TYPE_HEADER_OR_FOOTER) {
                    removeDetachedView(scrap, false);
                }
                return;
            }

@@ -4258,9 +4260,11 @@ public abstract class AbsListView extends AdapterView<ListAdapter> implements Te

                    activeViews[i] = null;

                    if (whichScrap == AdapterView.ITEM_VIEW_TYPE_IGNORE) {
                        removeDetachedView(victim, false);
                    if (!shouldRecycleViewType(whichScrap)) {
                        // Do not move views that should be ignored
                        if (whichScrap != ITEM_VIEW_TYPE_HEADER_OR_FOOTER) {
                            removeDetachedView(victim, false);
                        }
                        continue;
                    }