Error “You must not call setTag() on a view Glide is targeting” when use Glide

前端 未结 8 692
悲哀的现实
悲哀的现实 2020-12-13 09:15

I use Glide library inner custom adapter view in my apps. But I have Error :

\"You must not call setTag() on a view Glide is targeting\" 

T

8条回答
  •  南笙
    南笙 (楼主)
    2020-12-13 09:42

    As written by Thu Thu, you can simply reference an id of any existing View. For instance, suppose you want to set tag to an ImageView:

    image_view.setTag(R.id.image_view, 100)
    if (image_view.getTag(R.id.image_view) == 100) ...
    

提交回复
热议问题