pub enum Motion {
Fade,
Quick,
}Expand description
How long a change takes, as opposed to how long a state lasts.
See the crate header for why this is not a Moment. It grows from a
measurement rather than from the scale looking short.
Variants§
Fade
A thing leaving: opacity to zero, then gone.
The whole of the departure. A renderer that removes the node itself has to wait this out first, or it drops the animation mid-stroke.
Quick
A state answering a pointer or a press: a hover tone, a pressed bevel, a disclosure turning. Measured from the 0.1s and 0.2s hover literals GoingsOn, the server and multithreaded each wrote, and the 120ms quasi wrote for its disclosure; short enough to read as the control’s own response rather than as an animation.
Implementations§
Trait Implementations§
impl Copy for Motion
impl Eq for Motion
Source§impl Ord for Motion
impl Ord for Motion
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more
Source§impl PartialOrd for Motion
impl PartialOrd for Motion
impl StructuralPartialEq for Motion
Auto Trait Implementations§
impl Forget for Motion
impl Freeze for Motion
impl RefUnwindSafe for Motion
impl Send for Motion
impl Sync for Motion
impl Unpin for Motion
impl UnsafeUnpin for Motion
impl UnwindSafe for Motion
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more