public void Dispose() { if (this.updateWindow != null) { this.updateWindow.Close(); this.updateWindow = null; } }
void PerformUpdate(string downloadUrl, string fileName) { App.Current.Dispatcher.Invoke(new Action(() => { this.updateWindow = new UpdateWindow(downloadUrl, fileName); try { this.updateWindow.Owner = App.Current.BaseMainWindow; } catch { } this.updateWindow.ShowDialog(); })); }