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