ContextMenu constructor

ContextMenu({
  1. List<ContextMenuItem> menuItems = const [],
  2. void onCreateContextMenu(
    1. InAppWebViewHitTestResult
    )?,
  3. void onHideContextMenu()?,
  4. @Deprecated("Use settings instead") ContextMenuOptions? options,
  5. ContextMenuSettings? settings,
  6. void onContextMenuActionItemClicked(
    1. ContextMenuItem
    )?,
})

Officially Supported Platforms/Implementations:

  • Android WebView:
    • To make it work properly on Android, JavaScript should be enabled!
  • iOS WKWebView
  • macOS WKWebView

Implementation

ContextMenu({
  this.menuItems = const [],
  this.onCreateContextMenu,
  this.onHideContextMenu,
  @Deprecated("Use settings instead") this.options,
  this.settings,
  this.onContextMenuActionItemClicked,
});