wrap method
Оборачивает widget tree. Визуально shell-и применяются как middleware.
Implementation
@override
Widget wrap(CarpenterShellBuildContext context, Widget child) {
return CarpenterHotkeyScope(
commands: commands,
onCommand: (command) {
onCommand?.call(context.runtime, command);
},
controller: controller,
platform: platform,
enabled: enabled,
trackPressedKeys: trackPressedKeys,
autofocus: autofocus,
child: child,
);
}