prevent re-triggering on deactivated

case where without it the toggle hidden is fired and then ondeactivated is also fired but with delay, and hides the window again
This commit is contained in:
Jeremy 2021-11-23 19:46:34 +11:00
parent df4f94fdee
commit 7b4867d2eb

View file

@ -355,7 +355,7 @@ namespace Flow.Launcher
private async void OnDeactivated(object sender, EventArgs e)
{
if (_settings.HideWhenDeactive)
if (_settings.HideWhenDeactive && _viewModel.MainWindowVisibility != Visibility.Collapsed)
{
await Task.Delay(50);
_viewModel.Hide();