ursus
02/24/2024, 2:07 AMsealed class Foo {
data object Loading
data class Loaded(val counter: Int)
}
I display it via
AnumatedContent(foo) {
when (it) {
is Loading -> ProgressBar()
is Loaded -> Form(it.counter)
}
Now, when I change state from Foo.Loaded(0)
to Foo.Loaded(1)
I get a animation.
I don't want that.
I only want to animate changes between Loading and Loaded
Is there some equals lambda parameter I can pass in to modify the equaljty calculation?Albert Chang
02/24/2024, 3:41 AMcontentKey
parameter.ursus
02/24/2024, 2:27 PM