public void SetUp() { this.shortcutsMananger = new ShortcutsManager(); this.shortcut = new NiceShortcut(); this.shortcut.Name = "Winamp"; this.shortcut.Command = "Winamp"; this.shortcut.KeyCode = System.Windows.Forms.Keys.W; this.shortcut.Control = true; }
public static void Main() { try { Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); var shortcutsManager = new ShortcutsManager(); shortcutsManager.LoadShortcuts(); var frmShortcuts = new frmShortcuts(); shortcutsManager.RegisterShortcuts(frmShortcuts); Application.Run(frmShortcuts); shortcutsManager.UnregisterShortcuts(); } catch (Exception ex) { ShortcutsManager.ShowError(ex.Message); } }