FerroUI/ docs

Search guides, controls, Rust APIs, and XAML.

    GitHub ↗

    INavigation

    trait · ferroui-controls · v0.5.0

    trait INavigation: 'static
    

    Provides navigation operations for stack-based and modal page navigation. Exposed via the Navigation property of a page when the page is hosted in a navigation page.

    Not meant to be implemented by client code.

    The asynchronous members give the JoinHandle of a task of the dispatcher of the calling thread: awaited, it gives the outcome of the navigation, or a JoinError (Panicked when the navigation failed, Canceled when its task was aborted or the dispatcher shut down); dropped, the navigation goes on. Their deprecated ..._task forms give a DispatcherTask, which raises a failure again when it is observed.

    View source

    Members

    navigation_stack

    fn navigation_stack(self: &Self) -> Rc<Vec<Ref<Page>>>
    

    The current navigation stack. The root page is at index 0; the visible page is last.

    Source

    modal_stack

    fn modal_stack(self: &Self) -> Rc<Vec<Ref<Page>>>
    

    The current modal stack. Index 0 is the oldest (bottom-most) modal; the last index is the most recently pushed (topmost) modal.

    Source

    stack_depth

    fn stack_depth(self: &Self) -> i32
    

    The number of pages in the navigation stack.

    Source

    can_go_back

    fn can_go_back(self: &Self) -> bool
    

    Whether a pop operation is possible (the stack has more than one entry).

    Source

    push_async

    fn push_async(self: &Self, page: Ref<Page>) -> JoinHandle<()>
    

    Pushes page using the host's default transition.

    Source

    push_async_with_transition

    fn push_async_with_transition(self: &Self, page: Ref<Page>, transition: Option<Rc<dyn IPageTransition>>) -> JoinHandle<()>
    

    Pushes page using transition. Pass None for no animation.

    Source

    push_async_with_parameter

    fn push_async_with_parameter(self: &Self, _page: Ref<Page>, _transition: Option<Rc<dyn IPageTransition>>, _parameter: Option<BoxedValue>) -> JoinHandle<()>
    

    Pushes page using transition with an optional parameter.

    Source

    pop_async

    fn pop_async(self: &Self) -> JoinHandle<Option<Ref<Page>>>
    

    Pops the top page using the host's default transition.

    Source

    pop_async_with_transition

    fn pop_async_with_transition(self: &Self, transition: Option<Rc<dyn IPageTransition>>) -> JoinHandle<Option<Ref<Page>>>
    

    Pops the top page using transition. Pass None for no animation.

    Source

    pop_to_root_async

    fn pop_to_root_async(self: &Self) -> JoinHandle<()>
    

    Pops all pages above the root using the host's default transition.

    Source

    pop_to_root_async_with_transition

    fn pop_to_root_async_with_transition(self: &Self, transition: Option<Rc<dyn IPageTransition>>) -> JoinHandle<()>
    

    Pops all pages above the root using transition. Pass None for no animation.

    Source

    pop_to_page_async

    fn pop_to_page_async(self: &Self, page: Ref<Page>) -> JoinHandle<()>
    

    Pops all pages above page using the host's default transition.

    Source

    pop_to_page_async_with_transition

    fn pop_to_page_async_with_transition(self: &Self, page: Ref<Page>, transition: Option<Rc<dyn IPageTransition>>) -> JoinHandle<()>
    

    Pops all pages above page using transition. Pass None for no animation.

    Source

    replace_async

    fn replace_async(self: &Self, page: Ref<Page>) -> JoinHandle<()>
    

    Replaces the current top page with page using the host's default transition.

    Source

    replace_async_with_transition

    fn replace_async_with_transition(self: &Self, page: Ref<Page>, transition: Option<Rc<dyn IPageTransition>>) -> JoinHandle<()>
    

    Replaces the current top page with page using transition. Pass None for no animation.

    Source

    replace_async_with_parameter

    fn replace_async_with_parameter(self: &Self, _page: Ref<Page>, _transition: Option<Rc<dyn IPageTransition>>, _parameter: Option<BoxedValue>) -> JoinHandle<()>
    

    Replaces the current top page with page using transition with an optional parameter.

    Source

    push_modal_async

    fn push_modal_async(self: &Self, page: Ref<Page>) -> JoinHandle<()>
    

    Pushes page as a modal using the host's modal transition.

    Source

    push_modal_async_with_transition

    fn push_modal_async_with_transition(self: &Self, page: Ref<Page>, transition: Option<Rc<dyn IPageTransition>>) -> JoinHandle<()>
    

    Pushes page as a modal using transition. Pass None for no animation.

    Source

    push_modal_async_with_parameter

    fn push_modal_async_with_parameter(self: &Self, _page: Ref<Page>, _transition: Option<Rc<dyn IPageTransition>>, _parameter: Option<BoxedValue>) -> JoinHandle<()>
    

    Pushes page as a modal using transition with an optional parameter.

    Source

    pop_modal_async

    fn pop_modal_async(self: &Self) -> JoinHandle<Option<Ref<Page>>>
    

    Pops the top modal page using the host's modal transition.

    Source

    pop_modal_async_with_transition

    fn pop_modal_async_with_transition(self: &Self, transition: Option<Rc<dyn IPageTransition>>) -> JoinHandle<Option<Ref<Page>>>
    

    Pops the top modal page using transition. Pass None for no animation.

    Source

    pop_all_modals_async

    fn pop_all_modals_async(self: &Self) -> JoinHandle<()>
    

    Pops all modal pages, animating only the topmost dismissal.

    Source

    pop_all_modals_async_with_transition

    fn pop_all_modals_async_with_transition(self: &Self, transition: Option<Rc<dyn IPageTransition>>) -> JoinHandle<()>
    

    Pops all modal pages using transition. Pass None for no animation.

    Source

    push_async_task

    fn push_async_task(self: &Self, page: Ref<Page>) -> DispatcherTask<()>
    

    The deprecated form of push_async: a DispatcherTask.

    Deprecated since 0.5.0. use push_async, which gives a JoinHandle

    Source

    push_async_with_transition_task

    fn push_async_with_transition_task(self: &Self, page: Ref<Page>, transition: Option<Rc<dyn IPageTransition>>) -> DispatcherTask<()>
    

    The deprecated form of push_async_with_transition: a DispatcherTask.

    Deprecated since 0.5.0. use push_async_with_transition, which gives a JoinHandle

    Source

    push_async_with_parameter_task

    fn push_async_with_parameter_task(self: &Self, page: Ref<Page>, transition: Option<Rc<dyn IPageTransition>>, parameter: Option<BoxedValue>) -> DispatcherTask<()>
    

    The deprecated form of push_async_with_parameter: a DispatcherTask.

    Deprecated since 0.5.0. use push_async_with_parameter, which gives a JoinHandle

    Source

    pop_async_task

    fn pop_async_task(self: &Self) -> DispatcherTask<Option<Ref<Page>>>
    

    The deprecated form of pop_async: a DispatcherTask.

    Deprecated since 0.5.0. use pop_async, which gives a JoinHandle

    Source

    pop_async_with_transition_task

    fn pop_async_with_transition_task(self: &Self, transition: Option<Rc<dyn IPageTransition>>) -> DispatcherTask<Option<Ref<Page>>>
    

    The deprecated form of pop_async_with_transition: a DispatcherTask.

    Deprecated since 0.5.0. use pop_async_with_transition, which gives a JoinHandle

    Source

    pop_to_root_async_task

    fn pop_to_root_async_task(self: &Self) -> DispatcherTask<()>
    

    The deprecated form of pop_to_root_async: a DispatcherTask.

    Deprecated since 0.5.0. use pop_to_root_async, which gives a JoinHandle

    Source

    pop_to_root_async_with_transition_task

    fn pop_to_root_async_with_transition_task(self: &Self, transition: Option<Rc<dyn IPageTransition>>) -> DispatcherTask<()>
    

    The deprecated form of pop_to_root_async_with_transition: a DispatcherTask.

    Deprecated since 0.5.0. use pop_to_root_async_with_transition, which gives a JoinHandle

    Source

    pop_to_page_async_task

    fn pop_to_page_async_task(self: &Self, page: Ref<Page>) -> DispatcherTask<()>
    

    The deprecated form of pop_to_page_async: a DispatcherTask.

    Deprecated since 0.5.0. use pop_to_page_async, which gives a JoinHandle

    Source

    pop_to_page_async_with_transition_task

    fn pop_to_page_async_with_transition_task(self: &Self, page: Ref<Page>, transition: Option<Rc<dyn IPageTransition>>) -> DispatcherTask<()>
    

    The deprecated form of pop_to_page_async_with_transition: a DispatcherTask.

    Deprecated since 0.5.0. use pop_to_page_async_with_transition, which gives a JoinHandle

    Source

    replace_async_task

    fn replace_async_task(self: &Self, page: Ref<Page>) -> DispatcherTask<()>
    

    The deprecated form of replace_async: a DispatcherTask.

    Deprecated since 0.5.0. use replace_async, which gives a JoinHandle

    Source

    replace_async_with_transition_task

    fn replace_async_with_transition_task(self: &Self, page: Ref<Page>, transition: Option<Rc<dyn IPageTransition>>) -> DispatcherTask<()>
    

    The deprecated form of replace_async_with_transition: a DispatcherTask.

    Deprecated since 0.5.0. use replace_async_with_transition, which gives a JoinHandle

    Source

    replace_async_with_parameter_task

    fn replace_async_with_parameter_task(self: &Self, page: Ref<Page>, transition: Option<Rc<dyn IPageTransition>>, parameter: Option<BoxedValue>) -> DispatcherTask<()>
    

    The deprecated form of replace_async_with_parameter: a DispatcherTask.

    Deprecated since 0.5.0. use replace_async_with_parameter, which gives a JoinHandle

    Source

    push_modal_async_task

    fn push_modal_async_task(self: &Self, page: Ref<Page>) -> DispatcherTask<()>
    

    The deprecated form of push_modal_async: a DispatcherTask.

    Deprecated since 0.5.0. use push_modal_async, which gives a JoinHandle

    Source

    push_modal_async_with_transition_task

    fn push_modal_async_with_transition_task(self: &Self, page: Ref<Page>, transition: Option<Rc<dyn IPageTransition>>) -> DispatcherTask<()>
    

    The deprecated form of push_modal_async_with_transition: a DispatcherTask.

    Deprecated since 0.5.0. use push_modal_async_with_transition, which gives a JoinHandle

    Source

    push_modal_async_with_parameter_task

    fn push_modal_async_with_parameter_task(self: &Self, page: Ref<Page>, transition: Option<Rc<dyn IPageTransition>>, parameter: Option<BoxedValue>) -> DispatcherTask<()>
    

    The deprecated form of push_modal_async_with_parameter: a DispatcherTask.

    Deprecated since 0.5.0. use push_modal_async_with_parameter, which gives a JoinHandle

    Source

    pop_modal_async_task

    fn pop_modal_async_task(self: &Self) -> DispatcherTask<Option<Ref<Page>>>
    

    The deprecated form of pop_modal_async: a DispatcherTask.

    Deprecated since 0.5.0. use pop_modal_async, which gives a JoinHandle

    Source

    pop_modal_async_with_transition_task

    fn pop_modal_async_with_transition_task(self: &Self, transition: Option<Rc<dyn IPageTransition>>) -> DispatcherTask<Option<Ref<Page>>>
    

    The deprecated form of pop_modal_async_with_transition: a DispatcherTask.

    Deprecated since 0.5.0. use pop_modal_async_with_transition, which gives a JoinHandle

    Source

    pop_all_modals_async_task

    fn pop_all_modals_async_task(self: &Self) -> DispatcherTask<()>
    

    The deprecated form of pop_all_modals_async: a DispatcherTask.

    Deprecated since 0.5.0. use pop_all_modals_async, which gives a JoinHandle

    Source

    pop_all_modals_async_with_transition_task

    fn pop_all_modals_async_with_transition_task(self: &Self, transition: Option<Rc<dyn IPageTransition>>) -> DispatcherTask<()>
    

    The deprecated form of pop_all_modals_async_with_transition: a DispatcherTask.

    Deprecated since 0.5.0. use pop_all_modals_async_with_transition, which gives a JoinHandle

    Source

    insert_page

    fn insert_page(self: &Self, page: Ref<Page>, before: Ref<Page>)
    

    Inserts page immediately before before in the stack. Does not change the currently visible page.

    Panics

    Panics when before is not in the navigation stack, or page is already hosted by this navigation page.

    Source

    remove_page

    fn remove_page(self: &Self, page: Ref<Page>)
    

    Removes page from the navigation stack without animation. If page is not in the stack the call is a no-op.

    Source

    Availability

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