private void UnsubscribeEvents() { if (this.keyHoldHook != null) { this.keyHoldHook.KeyDownEvent -= OnKeyDown; this.keyHoldHook = null; } }
private void SubscribeEvents() { if (this.keyHoldHook == null) { this.keyHoldHook = new L45KeyHoldHook(); } this.keyHoldHook.KeyDownEvent += OnKeyDown; }
private void Unsubscribe() { if (this.keyHoldHook == null) { return; } ; this.keyHoldHook.KeyDownEvent -= OnKeyDown; this.keyHoldHook.KeyUpEvent -= OnKeyUp; this.keyHoldHook.KeyHoldEvent -= OnKeyHold; this.keyHoldHook.Dispose(); this.keyHoldHook = null; }
private void UnsubscribeKeyBindEvents() { if (this.bindHandler != null) { this.bindHandler.KeyHoldEvent -= OnBindedKeyHold; this.bindHandler.Dispose(); this.bindHandler = null; } if (this.keyHoldHook != null) { this.keyHoldHook.KeyHoldEvent -= OnKeyHold; this.keyHoldHook.Dispose(); this.keyHoldHook = null; } }
private void SubscribeKeyBindEvents() { if (keyHoldHook == null) { this.keyHoldHook = new L45KeyHoldHook(); } this.keyHoldHook.KeyHoldEvent += OnKeyHold; if (bindHandler == null) { this.bindHandler = new KeyBindHandler(this.keyHoldHook); } this.bindHandler.KeyHoldEvent += OnBindedKeyHold; }
private void SubscribeEvents() { if (this.keyHoldHook == null) { this.keyHoldHook = new L45KeyHoldHook(); } if (this.bindedKeyHoldManager == null) { this.bindedKeyHoldManager = new BindedKeyHoldManager(this.keyHoldHook); } this.bindedKeyHoldManager.BindedKeyHoldEvent += OnBindedKeyHoldEvent; if (this.windowControls == null) { this.windowControls = new WindowControls(this, this.keyHoldHook); } this.windowControls.WindowHideEvent += this.HideWindow; }
public BindedKeyHoldManager(L45KeyHoldHook keyHoldHook) { this.keyHoldHook = keyHoldHook; this.SubscribeKeyBindEvents(); }
public KeyBindHandler(L45KeyHoldHook keyHoldHook) { this.keyHoldHook = keyHoldHook; this.Subscribe(); }
public WindowControls(MainWindow window, L45KeyHoldHook keyHoldHook) { this.window = window; this.keyHoldHook = keyHoldHook; this.SubscribeEvents(); }