onChecked

inline fun CompoundButton.onChecked(crossinline block: () -> Unit)

Sets CompoundButton.OnCheckedChangeListener and calls specified function block if this button state changed to checked

See also