I've tried to set the ChangeListener to null, but without any success... Any thoughts ?

We are using MVVM and databinding but ran into an issue with RadioGroup, the current solution has a bindingAdapter connecting it into the ViewModel. But sometimes we wish to update the selected value but without triggering the onChange event -> how can this be removed?
I've tried to set the ChangeListener to null, but without any success... Any thoughts ?
You already invited:

Osazuwa

Upvotes from:

In the binding adapter also put a flag shouldAddListener and whenever it's false just make the listener as null. So it goes like this when you don't want onchangeevent to happen just first make shouldAddlistener as false and than make changes to selected value and than add the listener

If you wanna answer this question please Login or Register