private void ProcessCommand(ShortStroke _command) { foreach (KeyValuePair <ShortStroke, EventHandler> _pair in HookTable) { if (_command == _pair.Key) { _pair.Value(null, null); } } }
private void ProcessKey(Char e) { if (_activeModifier.Has(ModifierKey.Shift) || _activeModifier.Has(ModifierKey.Ctrl) || _activeModifier.Has(ModifierKey.Alt)) { CharTable.Add(e); ShortStroke _inputToCompare = new ShortStroke(_activeModifier, CharTable); ProcessCommand(_inputToCompare); } else if (e == '\u0009') { ShortStroke _inputToCompare = new ShortStroke(_activeModifier, CharTable); ProcessCommand(_inputToCompare); _activeModifier = _activeModifier.Remove(ModifierKey.Console); } else if (_activeModifier.Is(ModifierKey.Console)) { CharTable.Add(e); } }