showAlertDialogMessage method

dynamic showAlertDialogMessage({
  1. String? title,
  2. String content = "",
  3. double maxHeight = 150,
  4. VoidCallback? onDoneClick,
  5. VoidCallback? onCancelClick,
  6. String? titleButtonCancel,
  7. String? titleButtonDone,
})

Implementation

showAlertDialogMessage(
    {String? title,
    String content = "",
    double maxHeight = 150,
    VoidCallback? onDoneClick,
    VoidCallback? onCancelClick,
    String? titleButtonCancel,
    String? titleButtonDone}) {
  if (context == null) {
    return;
  }
  Future.delayed(Duration.zero, () {
    showDialog(
        context: context!,
        // barrierDismissible: false,
        builder: (BuildContext context) => Dialog(
            elevation: 0,
            shape: const RoundedRectangleBorder(
              borderRadius: BorderRadius.all(Radius.circular(24)),
            ),
            backgroundColor: Colors.transparent,
            child: DialogView(
              content: content,
              maxHeight: maxHeight,
              onDoneClick: onDoneClick,
              onCancelClick: onCancelClick,
              title: title,
              titleButtonCancel: titleButtonCancel,
              titleButtonDone: titleButtonDone,
            )));
  });
}