mirror of
https://github.com/Flow-Launcher/Flow.Launcher.git
synced 2026-03-11 08:54:32 +00:00
Fixed Progressbar Dispatcher Exception
This commit is contained in:
parent
a200adaa9f
commit
2c1e39f313
1 changed files with 3 additions and 5 deletions
|
|
@ -138,22 +138,20 @@ namespace Flow.Launcher
|
||||||
}
|
}
|
||||||
case nameof(MainViewModel.ProgressBarVisibility):
|
case nameof(MainViewModel.ProgressBarVisibility):
|
||||||
{
|
{
|
||||||
Dispatcher.Invoke(async () =>
|
Dispatcher.Invoke(() =>
|
||||||
{
|
{
|
||||||
if (_viewModel.ProgressBarVisibility == Visibility.Hidden && !isProgressBarStoryboardPaused)
|
if (_viewModel.ProgressBarVisibility == Visibility.Hidden && !isProgressBarStoryboardPaused)
|
||||||
{
|
{
|
||||||
await Task.Delay(50);
|
|
||||||
_progressBarStoryboard.Stop(ProgressBar);
|
_progressBarStoryboard.Stop(ProgressBar);
|
||||||
isProgressBarStoryboardPaused = true;
|
isProgressBarStoryboardPaused = true;
|
||||||
}
|
}
|
||||||
else if (_viewModel.MainWindowVisibilityStatus &&
|
else if (_viewModel.MainWindowVisibilityStatus &&
|
||||||
isProgressBarStoryboardPaused)
|
isProgressBarStoryboardPaused)
|
||||||
{
|
{
|
||||||
_progressBarStoryboard.Begin(ProgressBar, true);
|
_progressBarStoryboard.Begin(ProgressBar, true);
|
||||||
isProgressBarStoryboardPaused = false;
|
isProgressBarStoryboardPaused = false;
|
||||||
}
|
}
|
||||||
}, System.Windows.Threading.DispatcherPriority.Render);
|
});
|
||||||
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case nameof(MainViewModel.QueryTextCursorMovedToEnd):
|
case nameof(MainViewModel.QueryTextCursorMovedToEnd):
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue