pub trait AnimationUtilities {
Show 20 methods
// Required methods
fn animation(self, animation: Animation) -> Self;
fn animation_with_duration(
self,
animation: Animation,
duration_ms: u32,
) -> Self;
fn animation_once(self, animation: Animation) -> Self;
fn animation_repeat(self, animation: Animation, count: u32) -> Self;
fn fade_in(self) -> Self;
fn fade_out(self) -> Self;
fn slide_in_left(self) -> Self;
fn slide_in_right(self) -> Self;
fn slide_in_top(self) -> Self;
fn slide_in_bottom(self) -> Self;
fn zoom_in(self) -> Self;
fn zoom_out(self) -> Self;
fn wobble(self) -> Self;
fn shake(self) -> Self;
fn flip(self) -> Self;
fn heartbeat(self) -> Self;
fn hover_animation(self, animation: Animation) -> Self;
fn focus_animation(self, animation: Animation) -> Self;
fn animation_pause(self) -> Self;
fn animation_resume(self) -> Self;
}
Expand description
Trait for adding animation utilities to a class builder
Required Methods§
fn animation(self, animation: Animation) -> Self
Sourcefn animation_with_duration(self, animation: Animation, duration_ms: u32) -> Self
fn animation_with_duration(self, animation: Animation, duration_ms: u32) -> Self
Add animation with custom duration
Sourcefn animation_once(self, animation: Animation) -> Self
fn animation_once(self, animation: Animation) -> Self
Add animation that runs only once
Sourcefn animation_repeat(self, animation: Animation, count: u32) -> Self
fn animation_repeat(self, animation: Animation, count: u32) -> Self
Add animation that repeats a specific number of times
Sourcefn slide_in_left(self) -> Self
fn slide_in_left(self) -> Self
Add slide in from left animation
Sourcefn slide_in_right(self) -> Self
fn slide_in_right(self) -> Self
Add slide in from right animation
Sourcefn slide_in_top(self) -> Self
fn slide_in_top(self) -> Self
Add slide in from top animation
Sourcefn slide_in_bottom(self) -> Self
fn slide_in_bottom(self) -> Self
Add slide in from bottom animation
Sourcefn hover_animation(self, animation: Animation) -> Self
fn hover_animation(self, animation: Animation) -> Self
Add hover animation (animation only on hover)
Sourcefn focus_animation(self, animation: Animation) -> Self
fn focus_animation(self, animation: Animation) -> Self
Add focus animation (animation only on focus)
Sourcefn animation_pause(self) -> Self
fn animation_pause(self) -> Self
Pause animation
Sourcefn animation_resume(self) -> Self
fn animation_resume(self) -> Self
Resume animation
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.