예제 #1
0
		public CommandShortcut(KeyShortcut shortcut, CommandInfo cmd) {
			KeyShortcut = shortcut;
			CommandInfo = cmd;
		}
예제 #2
0
		public ProviderAndCommand(ICommandInfoProvider provider, CommandInfo cmd) {
			if (provider == null)
				throw new ArgumentNullException(nameof(provider));
			Provider = provider;
			Command = cmd;
		}
예제 #3
0
		public static CommandShortcut Create(KeyInput key1, KeyInput key2, CommandInfo cmd) => new CommandShortcut(new KeyShortcut(key1, key2), cmd);
예제 #4
0
		public static CommandShortcut CtrlShiftAlt(Key key, CommandInfo cmd) => new CommandShortcut(new KeyShortcut(key, ModifierKeys.Control | ModifierKeys.Shift | ModifierKeys.Alt), cmd);
예제 #5
0
		public static CommandShortcut Alt(Key key, CommandInfo cmd) => new CommandShortcut(new KeyShortcut(key, ModifierKeys.Alt), cmd);
예제 #6
0
		public static CommandShortcut Control(Key key, CommandInfo cmd) => new CommandShortcut(new KeyShortcut(key, ModifierKeys.Control), cmd);
예제 #7
0
		public static CommandShortcut Create(Key key, CommandInfo cmd) => new CommandShortcut(new KeyShortcut(key, ModifierKeys.None), cmd);