activate method
Cmd?
activate(
- KeyMsg msg
Attempts to activate this binding for msg.
Returns the result of handler when the binding is enabled and the
key matches msg, or null otherwise.
Implementation
Cmd? activate(KeyMsg msg) {
if (!enabled || handler == null) return null;
if (!matches(msg)) return null;
return handler!();
}