pub struct ToastManager { /* private fields */ }Expand description
Manages multiple toast notifications
Implementations§
Source§impl ToastManager
impl ToastManager
pub fn new() -> ToastManager
Available on crate feature
toast only.pub fn add(&mut self, toast: Toast)
Available on crate feature
toast only.pub fn clear(&mut self)
Available on crate feature
toast only.pub fn error(&mut self, message: impl Into<String>)
Available on crate feature
toast only.pub fn get_active(&self) -> &[Toast]
Available on crate feature
toast only.pub fn handle_click(&mut self, x: u16, y: u16, frame_area: Rect) -> bool
Available on crate feature
toast only.pub fn has_toasts(&self) -> bool
Available on crate feature
toast only.pub fn info(&mut self, message: impl Into<String>)
Available on crate feature
toast only.pub fn remove_expired(&mut self)
Available on crate feature
toast only.pub fn success(&mut self, message: impl Into<String>)
Available on crate feature
toast only.pub fn warning(&mut self, message: impl Into<String>)
Available on crate feature
toast only.Trait Implementations§
Source§impl Debug for ToastManager
impl Debug for ToastManager
Source§impl Default for ToastManager
impl Default for ToastManager
Source§fn default() -> ToastManager
fn default() -> ToastManager
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for ToastManager
impl RefUnwindSafe for ToastManager
impl Send for ToastManager
impl Sync for ToastManager
impl Unpin for ToastManager
impl UnsafeUnpin for ToastManager
impl UnwindSafe for ToastManager
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> 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