LiveDataDrawable

fun LiveDataDrawable(liveData: LiveData<Drawable>, initialDrawable: Drawable? = null)

Parameters

liveData

The drawable LiveData of which the current value is drawn. While the LiveDataDrawable is visible, getDrawable will match the value of liveData. This property is public to offer a convenient observer pattern clients can use to keep track of what this drawable is showing.

initialDrawable

The drawable that is shown initially before liveData has a value. Can be null, in which case nothing is drawn as long as liveData has no value set yet.