pub struct AlertDialogBuilder { /* private fields */ }
v4_10
only.Expand description
A builder-pattern type to construct AlertDialog
objects.
Implementations§
Source§impl AlertDialogBuilder
impl AlertDialogBuilder
Labels for buttons to show in the alert.
The labels should be translated and may contain
a _
character to indicate the mnemonic character.
If this property is not set, then a ‘Close’ button is automatically created.
Determines what happens when the Escape key is pressed while the alert is shown.
If this property holds the index of a button in buttons
,
then pressing Escape is treated as if that button was pressed. If it is -1
or not a valid index for the buttons
array, then an error is returned.
If buttons
is NULL
, then the automatically created ‘Close’ button
is treated as both cancel and default button, so 0 is returned.
Determines what happens when the Return key is pressed while the alert is shown.
If this property holds the index of a button in buttons
,
then pressing Return is treated as if that button was pressed. If it is -1
or not a valid index for the buttons
array, then nothing happens.
If buttons
is NULL
, then the automatically created ‘Close’ button
is treated as both cancel and default button, so 0 is returned.
Sourcepub fn build(self) -> AlertDialog
pub fn build(self) -> AlertDialog
Build the AlertDialog
.