Merge "Don't update height if recycler view was scrolled" into rvc-qpr-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
a7f7189c11
@@ -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;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user