Personally I would try to address that in a differ...
# announcements
d
Personally I would try to address that in a different way by having a fixed onClickListener I attach in onCreateView, and that listener would delegate to an object
var listener: (view: View) -> Unit = {}
I would consider swapping out the listeners in onPause()/onResume() to either do nothing in onPause() and something in onResume(). There are complications to trying to un-set an onclick listener rather than change it to something else. edit: adjusted the onClickListener to a function type so the lambda syntax works.