pub enum FocusIntent<O = (), M = ()> {
Show 16 variants
Next,
Prev,
Set(FocusTarget<O>),
Open(FocusTarget<O>),
Close(FocusTarget<O>),
Toggle(FocusTarget<O>),
RegisterPage(Vec<FocusTarget<O>>),
RegisterPageAndEnterSection {
targets: Vec<FocusTarget<O>>,
section: usize,
item_count: usize,
item: usize,
},
ShowModal {
data: M,
count: usize,
},
UpdateModal {
data: M,
count: usize,
},
ClearOverlay,
ExitCanvasForward,
ExitCanvasBackward,
EnterSection {
item_count: usize,
},
LeaveSection,
Activate,
}Expand description
O is the application’s overlay type (see FocusTarget); M is the
payload carried by a generic modal overlay (e.g. dialog content under the
dialog feature). Both default to ().
Variants§
Next
Prev
Set(FocusTarget<O>)
Open(FocusTarget<O>)
Close(FocusTarget<O>)
Toggle(FocusTarget<O>)
RegisterPage(Vec<FocusTarget<O>>)
RegisterPageAndEnterSection
ShowModal
Open a modal overlay carrying data with count selectable items
(0 for a non-interactive modal such as a loading dialog).
UpdateModal
Replace the open modal’s data and item count in place.
ClearOverlay
ExitCanvasForward
ExitCanvasBackward
EnterSection
LeaveSection
Activate
Act on the currently focused target: enter it if it is a section
registered with an item count, otherwise do nothing. Lets an
application route activation (Enter) to the focus manager instead of
matching on focus itself. See FocusManager::activate.
Trait Implementations§
Source§impl<O: Clone, M: Clone> Clone for FocusIntent<O, M>
impl<O: Clone, M: Clone> Clone for FocusIntent<O, M>
Source§fn clone(&self) -> FocusIntent<O, M>
fn clone(&self) -> FocusIntent<O, M>
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<O: PartialEq, M: PartialEq> PartialEq for FocusIntent<O, M>
impl<O: PartialEq, M: PartialEq> PartialEq for FocusIntent<O, M>
Source§fn eq(&self, other: &FocusIntent<O, M>) -> bool
fn eq(&self, other: &FocusIntent<O, M>) -> bool
Tests for
self and other values to be equal, and is used by ==.impl<O: Eq, M: Eq> Eq for FocusIntent<O, M>
impl<O, M> StructuralPartialEq for FocusIntent<O, M>
Auto Trait Implementations§
impl<O, M> Freeze for FocusIntent<O, M>
impl<O, M> RefUnwindSafe for FocusIntent<O, M>where
M: RefUnwindSafe,
O: RefUnwindSafe,
impl<O, M> Send for FocusIntent<O, M>
impl<O, M> Sync for FocusIntent<O, M>
impl<O, M> Unpin for FocusIntent<O, M>
impl<O, M> UnsafeUnpin for FocusIntent<O, M>where
M: UnsafeUnpin,
O: UnsafeUnpin,
impl<O, M> UnwindSafe for FocusIntent<O, M>where
M: UnwindSafe,
O: UnwindSafe,
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more