public void Handle() { foreach (var key in _keyCodes) { KeyboardInterface.SendKeyUp(key); } }
public void Handle() { var stack = new Stack <ScanCodeShort>(); foreach (var key in _keys) { KeyboardInterface.SendKeyDown(key); stack.Push(key); } Thread.Sleep(_delay); while (stack.Any()) { var key = stack.Pop(); KeyboardInterface.SendKeyUp(key); } }