FerroUI/ docs

Search guides, controls, Rust APIs, and XAML.

    GitHub ↗

    IPageTransition

    trait · ferroui-base · v0.5.0

    trait IPageTransition: 'static
    

    Interface for animations that transition between two pages.

    View source

    Members

    start

    fn start(self: &Self, from: Option<&Ref<Visual>>, to: Option<&Ref<Visual>>, forward: bool, cancellation_token: CancellationToken) -> JoinHandle<()>
    

    Starts the animation.

    from is the control that is being transitioned away from, if any, and to the control that is being transitioned to, if any. forward tells whether the transition goes forwards or backwards. The transition stops as it is when cancellation_token is cancelled.

    The result tracks the progress of the animation: the handle of a task of the dispatcher that ends with Ok(()) when the transition has ended or was cancelled, and with JoinError::Panicked when an animation of the transition could not be run (the failure is a value of the handle, which the caller handles).

    Source

    as_progress_page_transition

    fn as_progress_page_transition(self: &Self) -> Option<&dyn crate::animation::IProgressPageTransition>
    

    The transition as a progress-driven transition, if it is one.

    Source

    as_page_slide

    fn as_page_slide(self: &Self) -> Option<&crate::animation::PageSlide>
    

    The transition as a page slide, if it is one.

    Source

    as_composite_page_transition

    fn as_composite_page_transition(self: &Self) -> Option<&crate::animation::CompositePageTransition>
    

    The transition as a composite page transition, if it is one.

    Source

    Trait implementations

    Availability

    Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.