Animator

interface Animator(source)

Manages a set of AnimationPlans and updates them over time.

Inheritors

Types

Link copied to clipboard
interface AnimationBlock

Allows block-style animations to be defined and started. These animations are then grouped and managed by a top-level Animation. Callers are then able to monitor/cancel the entire group using the returned value.

Link copied to clipboard
interface Listener

Notified of an Animator's events.

Link copied to clipboard
abstract class NumericAnimationInfo<T, V>

Contains data about a numeric animation. This is an intermediate type that is generated in the process of building animations.

Properties

Link copied to clipboard

Listeners that are notified of changes to the Animator's running animations

Functions

Link copied to clipboard
abstract operator fun invoke(definitions: Animator.AnimationBlock.() -> Unit): Animation<Any>

Allows block-style animations to be defined and started.

abstract operator fun <T> invoke(animation: AnimationPlan<T>, onChanged: (T) -> Unit): Animation<T>

Starts the given animation and notifies of changes to the underlying value via onChanged.

Inherited functions

Link copied to clipboard
operator fun <V, T, K> Animator.invoke(default: T, using: NumericAnimationPlan<T, K>, onChanged: (old: T, new: T) -> Unit = { _,_ -> }): ReadWriteProperty<V, T>

Defines a property that can be animated using the given animation.

operator fun <T, V> Animator.invoke(range: Pair<T, T>, using: NumericAnimationPlan<T, V>, onChanged: (T) -> Unit): Animation<T>

Starts an animation from range.first to range.second.