Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/asp.net-mvc/16.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
带SectionIndexer的Android RecyclerView_Android_Listview_Android Recyclerview_Sectionindexer - Fatal编程技术网

带SectionIndexer的Android RecyclerView

带SectionIndexer的Android RecyclerView,android,listview,android-recyclerview,sectionindexer,Android,Listview,Android Recyclerview,Sectionindexer,有人知道如何使用SectionIndexer或RecyclerView的替代品吗?SectionIndexer允许ListView在快速滚动时弹出节。问题在于RecyclerView与ListView不同。RecyclerView仅回收视图,仅此而已。这就是为什么它也没有FastScroll选项的原因,你可能已经发现了 您现在可以做什么: 使用FastScroll实现LayoutManager,并实现您想要的效果 使用图书馆。(我找到了这个:但还没有测试过) 使用列表视图。我认为它并没有随着Re

有人知道如何使用SectionIndexer或RecyclerView的替代品吗?SectionIndexer允许ListView在快速滚动时弹出节。

问题在于RecyclerView与ListView不同。RecyclerView仅回收视图,仅此而已。这就是为什么它也没有FastScroll选项的原因,你可能已经发现了

您现在可以做什么:

  • 使用FastScroll实现LayoutManager,并实现您想要的效果
  • 使用图书馆。(我找到了这个:但还没有测试过)
  • 使用列表视图。我认为它并没有随着RecyclerView的发布而被弃用,因为它涵盖了像您这样的用例
  • 检查此问题以了解更多信息:

    一篇关于ListView和RecyclerView区别的有趣文章: