showAlertAndroidDialog method
Future<void>
showAlertAndroidDialog({
- required BuildContext context,
- String? title,
- String? content,
- String? textButton,
Implementation
Future<void> showAlertAndroidDialog(
{required BuildContext context,
String? title,
String? content,
String? textButton}) async {
await Future<void>.delayed(const Duration(milliseconds: 200));
return showDialogWithBody(
context,
AlertDialog(
title: Text(title ?? 'Alert'),
content: SingleChildScrollView(
child: SelectableText(content ?? ''),
),
actions: <Widget>[
TextButton(
onPressed: () {
hideAppDialog();
},
child: Text(textButton ?? 'Ok'),
),
],
),
);
}