pub struct ClosableTag {
pub close: AtomicBool,
}Expand description
A tag to mark a container as closable.
Usually set via UiBuilder::closable.
Ui::close will find the closest parent ClosableTag and set its close field to true.
Use Ui::should_close to check if close has been called.
Fields§
§close: AtomicBoolImplementations§
Source§impl ClosableTag
impl ClosableTag
pub const NAME: &'static str = "egui_close_tag"
Sourcepub fn should_close(&self) -> bool
pub fn should_close(&self) -> bool
Returns true if ClosableTag::set_close has been called.
Trait Implementations§
Source§impl Debug for ClosableTag
impl Debug for ClosableTag
Source§impl Default for ClosableTag
impl Default for ClosableTag
Source§fn default() -> ClosableTag
fn default() -> ClosableTag
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl !Freeze for ClosableTag
impl RefUnwindSafe for ClosableTag
impl Send for ClosableTag
impl Sync for ClosableTag
impl Unpin for ClosableTag
impl UnwindSafe for ClosableTag
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> 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