internal GlobalHotKeyManager(GlobalHotKeyEvents globalHotKeyEvents) { _globalHotKeyEvents = globalHotKeyEvents; _listener = new LowLevelKeyboardListener(); _listener.OnKeyDown += _listener_OnKeyDown; _listener.OnKeyUp += _listener_OnKeyUp; _listener.HookKeyboard(); }
public StartUpWindow() { InitializeComponent(); CheckCommandLineArgs(); _globalHotKeyEvents = new GlobalHotKeyEvents(); _globalHotKeyEvents.GlobalHotKeyOpenFormMessage += _globalHotKeyEvents_GlobalHotKeyOpenFormMessage; _notifyIconEvents = new NotifyIconEvents(); _notifyIconEvents.NotifyIconOpenFormEvent += _notifyIconEvents_NotifyIconOpenFormEvent; _notifyIconEvents.NotifyIconShowFormMessageEvent += _notifyIconEvents_NotifyIconShowFormMessageEvent; _notifyIconEvents.NotifyIconExitAppEvent += _notifyIconEvents_NotifyIconExitAppEvent; _notify = new Notify(_notifyIconEvents); _globalHotKeyManager = new GlobalHotKeyManager(_globalHotKeyEvents); }