public void SetShortcut(ModifierKey modifier, Key key) { NSEventModifierFlags nsModifier = KeyMapper.GetModifier(modifier); string mappedKey = KeyMapper.GetKey(key); ObjC.Call(Handle, "setKeyEquivalentModifierMask:", new UIntPtr((ulong)nsModifier)); ObjC.Call(Handle, "setKeyEquivalent:", NSString.Create(mappedKey)); }
public void SetShortcut(ModifierKey modifier, Key key) { SetShortcut(KeyMapper.GetModifier(modifier), KeyMapper.GetKey(key)); }