public ASFui() { while (!Util.CheckBinary()) { var result = MessageBox.Show(@"ASF binary setting not configured. Configure now?", @"ASF binary not found.", MessageBoxButtons.YesNo, MessageBoxIcon.Error); if (result == DialogResult.Yes) { Properties.Settings.Default.ASFBinary = "Setting not configured."; var settings = new SettingsForm(); settings.ShowDialog(); } else { Environment.Exit(-1); } } if (Util.CheckIfAsfIsRunning()) { MessageBox.Show(@"An instance of ASF is already running. Close it.", @"ASF already running.", MessageBoxButtons.OK, MessageBoxIcon.Error); Environment.Exit(-2); } InitializeComponent(); Util.CheckVersion(); _isLocal = Properties.Settings.Default.IsLocal; }
public ASFui() { Util.CheckVersion(); Util.UpgradeSettings(); while (!Util.CheckBinary()) { var result = MessageBox.Show(@"ASF binary setting not configured. Configure now?", @"ASF binary not found.", MessageBoxButtons.YesNo, MessageBoxIcon.Error); if (result == DialogResult.Yes) { Properties.Settings.Default.ASFBinary = "Setting not configured."; var settings = new SettingsForm(); settings.ShowDialog(); } else { Environment.Exit(-1); } } if (Util.CheckIfAsfIsRunning()) { var result = MessageBox.Show(@"An instance of ASF is already running. Switching to remote mode.", @"ASF already running.", MessageBoxButtons.OKCancel, MessageBoxIcon.Error); if (result == System.Windows.Forms.DialogResult.OK) { Settings.Default.IsLocal = false; Settings.Default.RemoteURL = Util.GetEndpointAddress(); } else { Environment.Exit(-2); } } InitializeComponent(); }
private void btnASFuiSettings_Click(object sender, EventArgs e) { var settings = new SettingsForm(); settings.ShowDialog(); }
private void btnASFuiSettings_Click(object sender, EventArgs e) { var settings = new SettingsForm(); settings.ShowDialog(); }