How to implement RecyclerView with section header depending on category?

前端 未结 4 1774
傲寒
傲寒 2020-12-25 15:12

I want to implement sections in my list. I have a list of tasks. List has a custom adapter which extends recyclerview swipe adapter as I have implemented swipe gesture to th

4条回答
  •  离开以前
    2020-12-25 15:49

    You can implement it with the library SectionedRecyclerViewAdapter as I explained in this post.

    In order to implement the SwipeLayout, don't extend RecyclerSwipeAdapter, extend SectionedRecyclerViewAdapter and implement the SwipeLayout in ItemViewHolder / onBindItemViewHolder as you have done.

提交回复
热议问题