This commit is contained in:
Hamza-Ayed
2024-06-25 15:04:31 +03:00
parent 2d83f0a45e
commit ce2dfa2ff4
18 changed files with 157 additions and 218 deletions

View File

@@ -840,7 +840,8 @@ class MapPassengerController extends GetxController {
update();
}
void getDialog(String title, midTitle, VoidCallback onPressed) {
void getDialog(String title, String? midTitle, VoidCallback onPressed) {
final textToSpeechController = Get.find<TextToSpeechController>();
Get.defaultDialog(
title: title,
titleStyle: AppStyle.title,
@@ -849,13 +850,11 @@ class MapPassengerController extends GetxController {
children: [
IconButton(
onPressed: () async {
final textToSpeechController =
Get.find<TextToSpeechController>();
await textToSpeechController.speakText(midTitle);
await textToSpeechController.speakText(title ?? midTitle!);
},
icon: const Icon(Icons.headphones)),
Text(
midTitle,
midTitle!,
style: AppStyle.title,
)
],
@@ -867,6 +866,7 @@ class MapPassengerController extends GetxController {
),
cancel: MyElevatedButton(
title: 'Cancel',
kolor: AppColor.redColor,
onPressed: () {
Get.back();
}));