1

I want to reverse the RecyclerView. One way to do this is:

LinearLayoutManager mLayoutManager = new LinearLayoutManager(this);
mLayoutManager.setReverseLayout(true);
mLayoutManager.setStackFromEnd(true);
// Set the layout manager to your recyclerView
recyclerView.setLayoutManager(mLayoutManager);

What is the difference if I set a reversed list to RecyclerView Adapter rather than calling setReverseLayout(true) and setStackFromEnd(true) on LayoutManager?

Yogesh Rathod
  • 111
  • 1
  • 8
  • Read https://developer.android.com/reference/android/support/v7/widget/LinearLayoutManager.html#setReverseLayout(boolean) – ADM Mar 28 '18 at 07:25
  • `setReverseLayout(true)` = **position 0** is the *first element of the not-reversed list* , reversed List = **position 0** *last element of the not-reversed List* nothing else !! – Santanu Sur Mar 28 '18 at 07:33

0 Answers0