void DisplayUpdate(bool open, KopsikApi.KopsikUpdateViewItem view) { if (InvokeRequired) { Invoke((MethodInvoker) delegate { DisplayUpdate(open, view); }); return; } if (open) { aboutWindowController.Show(); aboutWindowController.BringToFront(); } if (!view.IsUpdateAvailable) { return; } if (isUpgradeDialogVisible || aboutWindowController.Visible) { return; } isUpgradeDialogVisible = true; DialogResult dr = MessageBox.Show( "There's a new version of this app available (" + view.Version + ")." + Environment.NewLine + "Proceed with the download?", "New version available", MessageBoxButtons.YesNo, MessageBoxIcon.Question); isUpgradeDialogVisible = false; if (DialogResult.Yes == dr) { Process.Start(view.URL); } }
private void aboutToolStripMenuItem_Click(object sender, EventArgs e) { aboutWindowController.Show(); aboutWindowController.BringToFront(); }