private void OnHotKeyPressed(HotKeyPressedEventArgs e) { if (_handles.Contains(Native.GetForegroundWindow())) { HotKeyPressedInternal?.Invoke(this, e); e.Handled = true; } else { e.Handled = false; } }