private void OpenGameRetrieverProgress() { //MaximizeShell(); this.Dispatcher.Invoke((Action)delegate { gameRetrieverProgress = new GameRetrieverProgress(); gameRetrieverProgress.ShowInTaskbar = false; gameRetrieverProgress.Owner = Application.Current.MainWindow; while (!gameRetrieverProgress.IsVisible) { gameRetrieverProgress.Left = (Application.Current.MainWindow.ActualWidth - gameRetrieverProgress.Width) / 2; gameRetrieverProgress.Top = (Application.Current.MainWindow.ActualHeight - gameRetrieverProgress.Height) / 2; gameRetrieverProgress.Show(); } }); }
private void CloseGameRetrieverProgress() { if (gameRetrieverProgress != null) { this.Dispatcher.Invoke((Action)delegate { gameRetrieverProgress.Close(); }); gameRetrieverProgress = null; } }