marcos930807 / awesomeDialogs

A new Flutter package project for simple a awesome dialogs
Other
339 stars 110 forks source link

direction from right to left #136

Open alshueiliproject opened 9 months ago

alshueiliproject commented 9 months ago

How can I change the icon and button direction from right to left ?

my code

 Future<bool> promptExit() async {
    AwesomeDialog dlg = AwesomeDialog(
      context: context,
      dialogType: DialogType.question,
      animType: AnimType.bottomSlide,
      title: tr(context).coloseApp,
      desc: tr(context).coloseAppMsg,
      dismissOnTouchOutside: true,
      btnCancelOnPress: () => canExit = false,
      btnOkOnPress: () async {
        await Future.delayed(const Duration(milliseconds: 200));
        Navigator.pushReplacement(context, MaterialPageRoute(builder: (context) => exit(0)));

        canExit = true;
      },
      btnOkText: tr(context).yes,
      btnCancelText: tr(context).no,
    );

    await dlg.show();
    return Future.value(canExit);
  }