嵌套Scrollview滚动中的Recyclerview滚动,但不能像普通的Recyclerview或Nested Scrollview一样快速滚动 [英] Recyclerview inside Nested Scrollview scroll but does not fast scroll like normal Recyclerview or Nested Scrollview
问题描述
我正在NestedScrollView
内使用RecyclerView
,它可以工作.但是,当我在LinearLayout
内使用RecyclerView
时,它会根据手势以各种速度滚动.滚动倾听手势,如果我仅向上滑动一点,则滚动一点;而如果我非常快速地滑动,则滚动非常快.现在我的问题是NestedScrollView
中的RecyclerView
当然可以滚动,但是快速滚动不起作用.但是,我向上或向下滑动时,RecyclerView
或NestedScrollView
只能滚动一点.
I am using RecyclerView
inside NestedScrollView
and it works. But when I use RecyclerView
inside LinearLayout
or something, it scroll in various speed depending on gesture. The scroll listen to gesture and if I slide up only a bit, then it scroll a little bit while if I slide up really fast, then it scroll really fast. Now my problem is that RecyclerView
inside NestedScrollView
certainly scroll but fast scroll does not work. However I slide up fast or slow, RecyclerView
or NestedScrollView
only scroll a little bit.
如何使滚动视图内的NestedScrollView
或RecyclerView
以不同的速度滚动?
How can I make my NestedScrollView
or RecyclerView
inside that scroll view scroll in various speed?
推荐答案
尝试
recyclerView.setNestedScrollingEnabled(false);
这篇关于嵌套Scrollview滚动中的Recyclerview滚动,但不能像普通的Recyclerview或Nested Scrollview一样快速滚动的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!