matchesStep method

bool matchesStep(
  1. Key key,
  2. int index
)

Whether key matches sequence step index.

Implementation

bool matchesStep(Key key, int index) {
  if (index < 0 || index >= keys.length) return false;
  final spec = keys[index];
  return keyMatchesSingle(key, KeyBinding.withHelp([spec], spec, ''));
}