Struct native_dialog::MessageDialog [−][src]
Builds and shows message dialogs.
Implementations
impl<'a> MessageDialog<'a>
[src]
pub fn new() -> Self
[src]
pub fn set_title(self, title: &'a str) -> Self
[src]
Set the title of the dialog.
pub fn set_text(self, text: &'a str) -> Self
[src]
Set the message text of the dialog.
pub fn set_type(self, typ: MessageType) -> Self
[src]
Set the type of the message. This usually affects the icon shown in the dialog.
pub fn set_owner<W: HasRawWindowHandle>(self, window: &W) -> Self
[src]
Sets the owner of the dialog. On Unix and GNU/Linux, this is a no-op.
pub unsafe fn set_owner_handle(self, handle: RawWindowHandle) -> Self
[src]
Sets the owner of the dialog by raw handle. On Unix and GNU/Linux, this is a no-op.
Safety
It's the caller's responsibility that ensuring the handle is valid.
pub fn reset_owner(self) -> Self
[src]
Resets the owner of the dialog to nothing.
pub fn show_alert(self) -> Result<()>
[src]
Shows a dialog that alert users with some message.
pub fn show_confirm(self) -> Result<bool>
[src]
Shows a dialog that let users to choose Yes/No.
Trait Implementations
impl Default for MessageDialog<'_>
[src]
Auto Trait Implementations
impl<'a> RefUnwindSafe for MessageDialog<'a>
[src]
impl<'a> !Send for MessageDialog<'a>
[src]
impl<'a> !Sync for MessageDialog<'a>
[src]
impl<'a> Unpin for MessageDialog<'a>
[src]
impl<'a> UnwindSafe for MessageDialog<'a>
[src]
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,