Qt: Add message about unofficial builds auto-update incompatibility

This commit is contained in:
Connor McLaughlin 2020-08-06 22:37:30 +10:00
parent 72053e5500
commit f0e3373cb2
1 changed files with 21 additions and 1 deletions

View File

@ -836,7 +836,27 @@ void MainWindow::checkForUpdates(bool display_message)
if (!AutoUpdaterDialog::isSupported())
{
if (display_message)
QMessageBox::critical(this, tr("Updater Error"), tr("Updates are not supported on this build."));
{
QMessageBox mbox(this);
mbox.setWindowTitle(tr("Updater Error"));
mbox.setTextFormat(Qt::RichText);
QString message;
#ifdef WIN32
message =
tr("<p>Sorry, you are trying to update a DuckStation version which is not an official GitHub release. To "
"prevent incompatibilities, the auto-updater is only enabled on official builds.</p>"
"<p>To obtain an official build, please follow the instructions under \"Downloading and Running\" at the "
"link below:</p>"
"<p><a href=\"https://github.com/stenzek/duckstation/\">https://github.com/stenzek/duckstation/</a></p>");
#else
message = tr("Automatic updating is not supported on the current platform.");
#endif
mbox.setText(message);
mbox.setIcon(QMessageBox::Critical);
mbox.exec();
}
return;
}