IAnimator
trait · ferroui-base · v0.5.0
trait IAnimator: 'static
Interface for animator objects: the list of the key frames of one property of an animation, and the logic that plays them.
Members
property
fn property(self: &Self) -> Option<&'static FerroProperty>
The target property.
set_property
fn set_property(self: &Self, value: Option<&'static FerroProperty>)
count
fn count(self: &Self) -> usize
The number of key frames.
get
fn get(self: &Self, index: usize) -> Ref<AnimatorKeyFrame>
The key frame at index. Panics when out of range.
add
fn add(self: &Self, item: Ref<AnimatorKeyFrame>)
Adds a key frame. Key frames are expected in cue order.
animator_type
fn animator_type(self: &Self) -> TypeId
The type of the animator, by which key frames find their animator.
apply
fn apply(self: Rc<Self>, animation: &Animation, control: &Animatable, clock: Option<Rc<dyn IClock>>, match_: Rc<dyn IObservable<bool>>, on_complete: Option<Rc<dyn Fn() -> ()>>, should_pause_on_invisible: bool) -> Option<Rc<dyn IDisposable>>
Applies the animation to a control: the animation runs while
match_ is true.
Trait implementations
Availability
Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.