You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Mar 26, 2019. It is now read-only.
I want to change the number of columns/spans when the user rotates the device - I was doing this using GridLayoutManager#setSpanCount() but don't see a similar method available for SpannedGridLayoutManager. Does one exist and I'm just missing it?
I ended up re-creating the layout manager after device rotates but at least it seems like this would be good to add if it makes sense..
The text was updated successfully, but these errors were encountered:
Sorry for the late response. I don't think I understand your use case, since when the screen rotates the Activity / Fragment / any other view-based controller should be recreated and the RecyclerView and its LayoutManager with it.
Even if the RecyclerView didn't get recreated, there would be not much difference between just setting a new spanCount on the current LayoutManager and creating a new one with that new value, since resetting the spanCount would mean recalculating everything and recycling every view.
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
I want to change the number of columns/spans when the user rotates the device - I was doing this using GridLayoutManager#setSpanCount() but don't see a similar method available for SpannedGridLayoutManager. Does one exist and I'm just missing it?
I ended up re-creating the layout manager after device rotates but at least it seems like this would be good to add if it makes sense..
The text was updated successfully, but these errors were encountered: