setContextMenu method
Sets or updates the WebView context menu to be used next time it will appear.
Officially Supported Platforms/Implementations:
- Android native WebView
- iOS
Implementation
@override
Future<void> setContextMenu(ContextMenu? contextMenu) async {
Map<String, dynamic> args = <String, dynamic>{};
args.putIfAbsent("contextMenu", () => contextMenu?.toMap());
await channel?.invokeMethod('setContextMenu', args);
_inAppBrowser?.setContextMenu(contextMenu);
}