JieJo
Results
1
comments of
JieJo
> kotlin在fragment里删除一条数据后,调用哪个方法刷新列表呢? 目前试了这三种没能实现: adapter.removeAt(position) adapter.setNewInstance(list) adapter.notifyDataSetChanged() notifyItemChanged(position)也没刷新 试试:adapter.notifyItemRemoved(position), 虽然 adapter.removeAt(position)这个方法内部调用了 notifyItemRemoved(),但是我使用removeAt()时不生效,并且还会异常,手动再次调用 notifyItemRemoved() 即可刷新界面