PlatformMenuItem constructor Null safety
- {required String label,
- MenuSerializableShortcut? shortcut,
- VoidCallback? onSelected,
- Intent? onSelectedIntent}
Creates a const PlatformMenuItem.
The label attribute is required.
Implementation
const PlatformMenuItem({
required this.label,
this.shortcut,
this.onSelected,
this.onSelectedIntent,
}) : assert(onSelected == null || onSelectedIntent == null, 'Only one of onSelected or onSelectedIntent may be specified');