Enum cacao::appkit::TerminateResponse
source · [−]pub enum TerminateResponse {
Now,
Cancel,
Later,
}
Available on crate feature
appkit
only.Expand description
Used for determining how an application should handle quitting/terminating.
You return this in your AppController
should_terminate
method.
Variants
Now
Proceed with termination.
Cancel
App should not be terminated.
Later
It might be fine to proceed with termination later. Returning this value causes
Cocoa to run the run loop until should_terminate()
returns true
or false
.
This return value is for primarily for cases where you need to provide alerts in order to decide whether to quit.
Trait Implementations
sourceimpl Clone for TerminateResponse
impl Clone for TerminateResponse
sourcefn clone(&self) -> TerminateResponse
fn clone(&self) -> TerminateResponse
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for TerminateResponse
impl Debug for TerminateResponse
sourceimpl From<TerminateResponse> for NSUInteger
impl From<TerminateResponse> for NSUInteger
sourcefn from(response: TerminateResponse) -> NSUInteger
fn from(response: TerminateResponse) -> NSUInteger
Converts to this type from the input type.
impl Copy for TerminateResponse
Auto Trait Implementations
impl RefUnwindSafe for TerminateResponse
impl Send for TerminateResponse
impl Sync for TerminateResponse
impl Unpin for TerminateResponse
impl UnwindSafe for TerminateResponse
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more