Shortcuts constructor Null safety
Creates a const Shortcuts widget that owns the map of shortcuts and creates its own manager.
When using this constructor, manager will return null.
The child and shortcuts
arguments are required.
See also:
- Shortcuts.manager, a constructor that uses a ShortcutManager to manage the shortcuts list instead.
Implementation
const Shortcuts({
super.key,
required Map<ShortcutActivator, Intent> shortcuts,
required this.child,
this.debugLabel,
}) : _shortcuts = shortcuts,
manager = null,
assert(shortcuts != null),
assert(child != null);