pub enum DialogPolicy {
Surface,
Terminate,
}Expand description
What a Watchdog does when it finds a modal dialog.
Variants§
Surface
Bring the dialog to the front and leave it there to be answered.
The default, because a dialog is usually a sequence asking a question rather than a fault, and a host that kills the process on sight can never be driven by a user interface. The dialog is moved into the always-on-top band, so an external front end cannot bury it.
The deadline still means something: passing it logs that the dialog has gone unanswered, without acting on it.
Terminate
End the process once the deadline passes with a dialog on screen.
For a host with nobody to answer, where blocking forever is worse than dying. The dialog’s text is written to stderr first, so the log says what was being asked rather than only that the process died.
Trait Implementations§
Source§impl Clone for DialogPolicy
impl Clone for DialogPolicy
Source§fn clone(&self) -> DialogPolicy
fn clone(&self) -> DialogPolicy
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more