Ruckus
07/21/2017, 4:31 PMfun sequential(animations: Collection<Animation>) = SequentialTransition().apply { children.setAll(animations) }
, the last line of my example could be sequential(animations).play()
.Ruckus
07/21/2017, 4:32 PMz
)edvin
07/21/2017, 4:32 PManimations.playSequentially()
Ruckus
07/21/2017, 4:32 PMedvin
07/21/2017, 4:33 PMedvin
07/21/2017, 4:33 PMRuckus
07/21/2017, 4:34 PMedvin
07/21/2017, 4:37 PMRuckus
07/21/2017, 4:53 PMplay
is true by default, which is great for simple things, but sucks when you're trying to chain. We may want to revisit that decision, but it would be a breaking change.Ruckus
07/21/2017, 4:54 PMedvin
07/21/2017, 4:56 PMcarlw
07/21/2017, 4:57 PMedvin
07/21/2017, 4:58 PMIterable<Animation>
instead of Collection
?edvin
07/21/2017, 4:58 PMRuckus
07/21/2017, 5:00 PM(r1.move(...) then r2.move(...)).play()
Ruckus
07/21/2017, 5:02 PMIterable<Animation>
would be a better idea, but the function definition would have to change (addAll
expects a collection, probably to avoid infinite iterables).edvin
07/21/2017, 5:04 PMiterable.toList()
?Ruckus
07/21/2017, 5:05 PMedvin
07/21/2017, 5:05 PMCollection
first so we don't create junk objectsRuckus
07/21/2017, 5:05 PMedvin
07/21/2017, 5:05 PMcarlw
07/21/2017, 5:08 PMRuckus
07/21/2017, 5:09 PMRuckus
07/21/2017, 5:09 PMcarlw
07/21/2017, 5:10 PMcarlw
07/21/2017, 5:10 PMcarlw
07/21/2017, 5:10 PMRuckus
07/21/2017, 5:12 PMRuckus
07/21/2017, 5:12 PMcarlw
07/21/2017, 5:29 PM