-
Notifications
You must be signed in to change notification settings - Fork 321
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
对于比较复杂的headerview 向上滑动显示headerview的时候会出现抖动 #9
Comments
:看了下listview的源码 发现headerview 是一个fix view 不会参与recycle 所以headerview复杂的时候不会有任何影响 而recycleview本身并不支持headerview 所以内部没有做相关的特殊处理 这导致headerview过于复杂然后重新recycle显示的时候会卡顿 请问有什么解决办法吗? |
我看了你的邮件,我觉得你所说的复杂的View(长达三四屏),不适合用到Recycleview这种频繁回收的场景,可以考虑用其他方式实现,比如NestedScrolling机制。 |
嗯嗯 好的我去试试 |
还问下 listview加复杂header的话 不会出现卡顿 看了下源码 发现listview的 header不会被回收 是因为这个原因吗 |
@lytasky 但是,RecyclerView本身不提供addHeader这种方法,HeaderAndFooterRecyclerView这个项目其实就是把Header和Footer当成普通的item来处理,所以你加上的headerView肯定会参与回收的,所以add一个太复杂的View是不适合的(太复杂的View也确实不应该增加到RecyclerView这种控件中,应该用其他方案开实现)。 |
@lytasky 兄弟,这个问题后来有解决吗。我现在也碰到了- -,不想用NestScrollView套RV,这样没法复用item呀 |
对于比较复杂的headerview 向上滑动显示headerview的时候会出现抖动 ,请问你这边遇到过吗?比如headerview长达3屏
The text was updated successfully, but these errors were encountered: