I have a Recyclerview with a Cardview and inside there is another Recyclerview like Netflix. So I cann scroll vertical and horizontal. Insider the inner recyclerview there are some cardviews with buttons. My Problem is if I scroll down and up again, then there apears some Space inside the Carview.
How does this happen?
Start
After Scrolling
Any suggestion or idea is helpful.
Note: Without the Itemdecoration (Page Indikator) it works and no Space appears.
Related
I have a RecyclerView where each item is a linear layout (orientation vertical) with a text view and another horizontal RecyclerView. The expected behaviour would be that the user would be able to seamless change from vertical to horizontal scroll, but it appears if user tries to swipe horizontally while the vertical scroll is not entirely stopped (yet not visible move, just to swipe fast) or if the horizontal swipe starts somehow from a diagonal motion, the app keeps the vertical scroll and ignores the horizontal one.
Is there a best practice on how to use a vertical recyclerview with horizontal recyclerview items? Tried to search for this a lot, but nothing seems to work.
I have a MotionLayout which basically contains an image and a ViewPager. The ViewPager renders a fragment with a RecyclerView in it.
At first the image has normal size, when i drag up, the image reduces its size and the ViewPager (with the RecyclerView within it) expands.
The problem is that the MotionLayout keeps intercepting the scroll action, so if the RecyclerView is expanded, and the user scrolls down, the MotionLayout will expand the image, rather than letting the RecyclerView scroll.
What i would expect is that the MotionLayout will expand the top image only if the RecyclerView has reached the first element, in that case since the RecyclerView cannot scroll anymore, the scroll action would be managed by the MotionLayout.
I am aware that within MotionLayout I can set the attribute moveWhenScrollAtTop="true" to get that behaviour, but that only works if there is just a RecyclerView, but not if the RecyclerView is within a ViewPager.
Has anyone faced this issue?
if your xml file contains nested scrollview just add android:nestedScrollingEnabled="false"
My layout is ConstraintLayout and hierarchy is like this:
There is top view area that takes half of the screen, below that a TabLayout and ViewPager. In this ViewPager there are 3 tabs which contain a RecyclerView. When any RecyclerView is scrolled, top area collapses to 10% of height and ViewPager expands. Due to this RecyclerView expands too. However, after this expansion, RecyclerView items stars overlapping too.
What could be the cause of this?
If you use the ConstraintLayout and enable animation for each item when has changed. Let disable that issue will be resolved.
android:animateLayoutChanges="false"
I have one RecyclerView inside Bottom Sheet and I don't want recyclerview to be scrollable inside it. But here I am facing a problem that Bottom Sheet expand and Collapse swipe property interfere with Recyclerview scroll and nothing is happening when I swipe. Please help me to solve this issue.
I have a situation where I have a Recyclerview which slides horizontally inside a ScrollView. Now the situation is when I do a horizontal swipe on the Recyclerview, instead of scrolling the cardviews inside Recyclerview, it scrolls the screen up, which disturbs the user experience.
Any solution or approach to avoid vertical scrolling when the person is doing a horizontal swipe on Recyclerview?
The solution is actually quite simple.
put the horizontal RecycleView as an item in a RecycleView, instead of using a scrollview.
then when you scroll it behaves as you want it to.
Thats what I did and it works perfectly