«Не удалось обработать информацию о маршруте» при запуске телефона в Flutter IOSIOS

Программируем под IOS
Anonymous
«Не удалось обработать информацию о маршруте» при запуске телефона в Flutter IOS

Сообщение Anonymous »

Я пытаюсь создать приложение Flutter и попытаться запустить Difle Dialpad с помощью (url_launcher: ^6.3.1). Это работает в Android, но не в iOS. />[ERROR:flutter/shell/platform/darwin/ios/framework/Source/FlutterViewController.mm(1869)] Failed to handle route information in Flutter.
flutter: Trying to launch: tel:

Here is my code
Future launchDialer(String? phoneNumber) async {
if (phoneNumber == null || phoneNumber.isEmpty) {
debugPrint("Phone number is null or empty.");
return;
}

final Uri telUri = Uri(scheme: 'tel', path: phoneNumber);
debugPrint("Trying to launch: $telUri");

try {
if (await canLaunchUrl(telUri)) {
final bool launched = await launchUrl(
telUri,
mode: LaunchMode.externalApplication, // safer for iOS
);
if (!launched) {
debugPrint("Launch failed.");
}
} else {
debugPrint("Can't launch the dialer with $telUri");
}
} catch (e) {
debugPrint("Exception while launching dialer: $e");

}
}

< /code>
info.plist:
LSApplicationQueriesSchemes

tel



Подробнее здесь: https://stackoverflow.com/questions/795 ... lutter-ios

Вернуться в «IOS»