private void pressKeysFor(PlatformActionType type) { var binding = host.PlatformKeyBindings.First(b => ((PlatformAction)b.Action).ActionType == type); foreach (var k in binding.KeyCombination.Keys) { InputManager.PressKey((Key)k); } foreach (var k in binding.KeyCombination.Keys) { InputManager.ReleaseKey((Key)k); } }
public PlatformAction(PlatformActionType actionType, PlatformActionMethod?actionMethod = null) { ActionType = actionType; ActionMethod = actionMethod; }