FlexBoxLayoutManager Scrolling Issue
See original GitHub issueI have a RecyclerView
that has a FlexboxLayoutManager
(as new FlexboxLayoutManager(FlexDirection.ROW)
).
When I add an item to the RecyclerView
I want to scroll to the newest item using scrollToPosition(adapter.getItemCount() - 1)
.
The problem is that when I do that, after filling a line, the next scroll causes the first column of the last row to scroll to the top of the RecyclerView
, and the rest of the RecyclerView
is filled with empty space so all the items above it are scrolled off the screen.
You can see this behavior in the sample app of this library that uses FlexboxLayoutManager
(in the flexbox
branch). Just click the FAB to start adding items.
Issue Analytics
- State:
- Created 7 years ago
- Comments:6 (4 by maintainers)
Top Results From Across the Web
FlexboxLayoutManager item flickering on scrolling of another ...
The first recyclerview item is flickering when scrolling on another recyclerView. It's working fine when item count of RecyclerView 1 is less ...
Read more >RecyclerView within NestedScrollView Scrolling Issue - Medium
Now what kinda problem occurred when we used nestedScrollView and put recyclerView inside nestedScrollView , it scrolls at various speeds depending on gestures....
Read more >Build flexible layouts with FlexboxLayout
LayoutManager , now you can make use of the Flexbox functionalities in a scrollable container in much more memory-efficient way.
Read more >flexbox-layout changelog - Awesome Android | LibHunt
#2; FlexboxLayoutManager can now scroll both directions #215 ... #283; Fixes the issue that the index of the view becomes inconsistent #311 ...
Read more >Flexbox inside the RecyclerView as a LayoutManager ...
Flexbox with a large number of items in a scrollable container! ... FlexboxLayout, FlexboxLayoutManager (RecyclerView) ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Found that there was an issue in the layout logic when scrollTo position was called with a new item in the adapter.
I’ll release a fixed version anytime soon.
Should be fixed by #231.