pub struct ActiveOverlay {
pub handle: OverlayHandle,
pub config: OverlayConfig,
pub state: OverlayState,
pub cached_size: Option<(f32, f32)>,
/* private fields */
}Expand description
An active overlay instance
Fields§
§handle: OverlayHandleHandle for this overlay
config: OverlayConfigConfiguration
state: OverlayStateCurrent state
cached_size: Option<(f32, f32)>Cached content size after layout (for positioning)
Implementations§
Source§impl ActiveOverlay
impl ActiveOverlay
Sourcepub fn is_visible(&self) -> bool
pub fn is_visible(&self) -> bool
Check if overlay should be visible
Sourcepub fn build_content(&self) -> Div
pub fn build_content(&self) -> Div
Build the overlay content
Sourcepub fn transition(&mut self, event: u32) -> bool
pub fn transition(&mut self, event: u32) -> bool
Transition to a new state
When transitioning to Closing state, this will automatically trigger
the exit animation on any motion container with the overlay’s motion key
(if configured via OverlayConfig.motion_key).
Sourcepub fn animation_progress(&self, current_time_ms: u64) -> Option<(f32, bool)>
pub fn animation_progress(&self, current_time_ms: u64) -> Option<(f32, bool)>
Get the current animation progress (0.0 to 1.0)
Returns (progress, is_entering) where:
- progress: 0.0 = start of animation, 1.0 = end
- is_entering: true for enter animation, false for exit
Returns None if not animating (fully visible or closed)
Auto Trait Implementations§
impl Freeze for ActiveOverlay
impl !RefUnwindSafe for ActiveOverlay
impl Send for ActiveOverlay
impl Sync for ActiveOverlay
impl Unpin for ActiveOverlay
impl UnsafeUnpin for ActiveOverlay
impl !UnwindSafe for ActiveOverlay
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