How to change particular image in recycler view after clicking

前端 未结 4 2028
别那么骄傲
别那么骄傲 2021-02-03 16:04

I want to change respective image of clicked item in recycler view. Now whats happening is if i click on item 2 image is changing at random item position in the list

<         


        
4条回答
  •  名媛妹妹
    2021-02-03 16:36

    Change the image value in the object at the clicked position and Call notifyItemChanged(position).Also handle the image change in Bindviewholder(ViewHolder holder,position) method of the Adapter.

提交回复
热议问题