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

Commit a7f7189c authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Don't update height if recycler view was scrolled" into rvc-qpr-dev

parents f3c9998a b85215ff
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -2640,7 +2640,10 @@ public class ChooserActivity extends ResolverActivity implements
        }
        RecyclerView recyclerView = mChooserMultiProfilePagerAdapter.getActiveAdapterView();
        ChooserGridAdapter gridAdapter = mChooserMultiProfilePagerAdapter.getCurrentRootAdapter();
        if (gridAdapter == null || recyclerView == null) {
        // Skip height calculation if recycler view was scrolled to prevent it inaccurately
        // calculating the height, as the logic below does not account for the scrolled offset.
        if (gridAdapter == null || recyclerView == null
                || recyclerView.computeVerticalScrollOffset() != 0) {
            return;
        }