Reputation: 51
For example the recyclerview should show one image at the same time and other image should be shown when the recyclerview is swiped horizontally.(https://i.sstatic.net/4BBrs.jpg)
I use Linear Layout as horizontally to show images.
Upvotes: 0
Views: 124
Reputation: 51
I've found a solution. I wanted to show just one item or image at the same time in a recylerview and when the recyclerview is swiped next item would be shown to the user. That work is just basic as adding that piece of code in the below after making the configuration of your recylerview.
PagerSnapHelper().attachToRecyclerView(yourRecyclerView)
Upvotes: 1