airbnb / epoxy

Epoxy is an Android library for building complex screens in a RecyclerView
https://goo.gl/eIK82p
Apache License 2.0
8.51k stars 728 forks source link

How to force rebinding view? #1339

Open mobilekosmos opened 1 year ago

mobilekosmos commented 1 year ago

I have list items with clickable icons, onClick I replace the icon by a progress view, the problem is how do I communicate to the listItem that the progress should reset? If I call requestModelBuild() that does nothing because the list item itself doesn't change, so I cannot force rebinding the view?

ha-0797 commented 1 year ago

You can create an EpoxyModelClass and add that onClick functionality in the override fun setDataBindingVariables(binding: ViewDataBinding?)