pub struct ModalConfig {
pub parent: TeksiloWindowId,
pub focus_target: Option<WidgetId>,
}Expand description
Parent + focus wiring for a modal window.
Modal is an Option<ModalConfig> on WindowConfig; the type
system enforces that a modal always names a parent, something a
modal: bool + parent: Option<...> split could not express.
Fields§
§parent: TeksiloWindowIdWindow whose input is blocked while this modal is open. Also the window the modal is transient for (Z-order parent on every OS).
focus_target: Option<WidgetId>Explicit initial-focus target inside the modal’s root subtree.
When None the framework falls back to the root widget’s
initial_focus_hint, then first_focusable_descendant.
Trait Implementations§
Source§impl Clone for ModalConfig
impl Clone for ModalConfig
Source§fn clone(&self) -> ModalConfig
fn clone(&self) -> ModalConfig
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 moreAuto Trait Implementations§
impl Freeze for ModalConfig
impl RefUnwindSafe for ModalConfig
impl Send for ModalConfig
impl Sync for ModalConfig
impl Unpin for ModalConfig
impl UnsafeUnpin for ModalConfig
impl UnwindSafe for ModalConfig
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