本文介绍了安卓:HorizontalScrollView内滚动型的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有多个 HorizontalScrollViews 在滚动型。横向滚动不顺畅的。我必须滚动近乎完美的水平滚动工作。有没有一个简单的解决方法来调整这种???谢谢!
I have multiple HorizontalScrollViews inside a ScrollView. Horizontal scroll isn't smooth at all. I have to scroll almost perfectly horizontally for scrolling to work. Is there a simple fix to tweak this ??? Thanks!
推荐答案
您可以使用回收站视图交错布局管理器
You can use Recycler view with Staggered layout manager
StaggeredGridLayoutManager staggeredGridLayoutManager = new StaggeredGridLayoutManager(4, StaggeredGridLayoutManager.HORIZONTAL);
RecyclerViewAdapter recyclerViewAdapter = newRecyclerViewAdapter(this);
recyclerView.setAdapter(recyclerViewAdapter); //Don't miss to initialize your adapter
这篇关于安卓:HorizontalScrollView内滚动型的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!