StandardDialog.show constructor
StandardDialog.show(
- BuildContext context, {
- Widget? icon,
- String? title,
- required Widget content,
- required String buttonTitle,
- required dynamic onAccept(),
- dynamic onCancel()?,
- Color? buttonColor,
- Color? cancelButtonColor,
- required String cancelButtonTitle,
- required bool shouldCloseOnMainButton,
- required Color backgroundColor,
- required bool disableTintColor,
Implementation
StandardDialog.show(
this.context, {
this.icon,
this.title,
required this.content,
required this.buttonTitle,
required this.onAccept,
this.onCancel,
this.buttonColor,
this.cancelButtonColor,
required this.cancelButtonTitle,
required this.shouldCloseOnMainButton,
required this.backgroundColor,
required this.disableTintColor,
}){
// Decide dialog layout based on platform
if (Platform.isIOS) {
_cupertinoView();
} else if (Platform.isAndroid) {
_materialView();
} else {
_materialView();
}
}