show method
dynamic
show()
弹出dialog
Implementation
show() {
showDialog(
context: context,
barrierDismissible: false,
builder: (BuildContext context) {
return this;
}).then((value) {
if (value == mainButtonText) {
if (onMainButtonClick != null) {
onMainButtonClick!();
}
} else {
if (onSecondaryButtonClick != null) {
onSecondaryButtonClick!();
}
}
});
}