CupertinoContextMenu.builder constructor

CupertinoContextMenu.builder(
  1. {Key? key,
  2. required List<Widget> actions,
  3. required CupertinoContextMenuBuilder builder,
  4. bool enableHapticFeedback = false}
)

Creates a context menu with a custom builder controlling the widget.

Use instead of the default constructor when it is needed to have a more custom animation.

The actions parameter cannot be empty.

Implementation

CupertinoContextMenu.builder({
  super.key,
  required this.actions,
  required this.builder,
  this.enableHapticFeedback = false,
}) : assert(actions.isNotEmpty),
     child = null,
     previewBuilder = null;