/// <summary> /// User clicks on "update". /// </summary> /// <param name="sender">ignored</param> /// <param name="e">ignored</param> private void btnUpdateCheck_Click(object sender, EventArgs e) { // check if an error is possible Update u = new Update(false, this); if (u.hadErrors) return; // update available? if (u.checkUpdate()) { // open url, if the user wants if (RTLMessageBox.Show(this, Program.res.GetString("BOX_UpdateInformation") .Replace("%s", u.getVersion()), MessageBoxButtons.YesNoCancel, MessageBoxDefaultButton.Button1, MessageBoxIcon.Information) == DialogResult.Yes) openUrl(u.getUpdateUrl()); } // no update found else RTLMessageBox.Show(this, Program.res.GetString("BOX_UpdateNone"), MessageBoxIcon.Information); }