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.
Members
navigation_stackmodal_stackstack_depthcan_go_backpush_asyncpush_async_with_transitionpush_async_with_parameterpop_asyncpop_async_with_transitionpop_to_root_asyncpop_to_root_async_with_transitionpop_to_page_asyncpop_to_page_async_with_transitionreplace_asyncreplace_async_with_transitionreplace_async_with_parameterpush_modal_asyncpush_modal_async_with_transitionpush_modal_async_with_parameterpop_modal_asyncpop_modal_async_with_transitionpop_all_modals_asyncpop_all_modals_async_with_transitionpush_async_taskpush_async_with_transition_taskpush_async_with_parameter_taskpop_async_taskpop_async_with_transition_taskpop_to_root_async_taskpop_to_root_async_with_transition_taskpop_to_page_async_taskpop_to_page_async_with_transition_taskreplace_async_taskreplace_async_with_transition_taskreplace_async_with_parameter_taskpush_modal_async_taskpush_modal_async_with_transition_taskpush_modal_async_with_parameter_taskpop_modal_async_taskpop_modal_async_with_transition_taskpop_all_modals_async_taskpop_all_modals_async_with_transition_taskinsert_pageremove_page
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.
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.
stack_depth
fn stack_depth(self: &Self) -> i32
The number of pages in the navigation stack.
can_go_back
fn can_go_back(self: &Self) -> bool
Whether a pop operation is possible (the stack has more than one entry).
push_async
fn push_async(self: &Self, page: Ref<Page>) -> JoinHandle<()>
Pushes page using the host's default transition.
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.
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.
pop_async
fn pop_async(self: &Self) -> JoinHandle<Option<Ref<Page>>>
Pops the top page using the host's default transition.
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.
pop_to_root_async
fn pop_to_root_async(self: &Self) -> JoinHandle<()>
Pops all pages above the root using the host's default transition.
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.
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.
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.
replace_async
fn replace_async(self: &Self, page: Ref<Page>) -> JoinHandle<()>
Replaces the current top page with page using the host's default
transition.
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.
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.
push_modal_async
fn push_modal_async(self: &Self, page: Ref<Page>) -> JoinHandle<()>
Pushes page as a modal using the host's modal transition.
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.
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.
pop_modal_async
fn pop_modal_async(self: &Self) -> JoinHandle<Option<Ref<Page>>>
Pops the top modal page using the host's modal transition.
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.
pop_all_modals_async
fn pop_all_modals_async(self: &Self) -> JoinHandle<()>
Pops all modal pages, animating only the topmost dismissal.
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.
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 aJoinHandle
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 aJoinHandle
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 aJoinHandle
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 aJoinHandle
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 aJoinHandle
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 aJoinHandle
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 aJoinHandle
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 aJoinHandle
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 aJoinHandle
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 aJoinHandle
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 aJoinHandle
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 aJoinHandle
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 aJoinHandle
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 aJoinHandle
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 aJoinHandle
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 aJoinHandle
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 aJoinHandle
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 aJoinHandle
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 aJoinHandle
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.
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.
Availability
Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.