defaultLinkActionPickerDelegate function
Future<LinkMenuAction>
defaultLinkActionPickerDelegate(
- BuildContext context,
- String link,
- Node node
Implementation
Future<LinkMenuAction> defaultLinkActionPickerDelegate(
BuildContext context, String link, Node node) async {
switch (defaultTargetPlatform) {
case TargetPlatform.iOS:
return _showCupertinoLinkMenu(context, link);
case TargetPlatform.android:
return _showMaterialMenu(context, link);
default:
assert(
false,
'defaultShowLinkActionsMenu not supposed to '
'be invoked for $defaultTargetPlatform');
return LinkMenuAction.none;
}
}