Reformat the update-related text to better accommodate translations

This commit is contained in:
Alexander Babikov
2025-08-14 05:24:21 +05:00
parent 6141b780ec
commit ac24f107f3
28 changed files with 335 additions and 99 deletions

View File

@@ -84,7 +84,12 @@ UpdateCheckDialog::upToDate()
ui->progressBar->setMaximum(100);
ui->progressBar->setValue(100);
ui->statusLabel->setVisible(true);
const auto statusText = tr("You are running the latest %1 version of 86Box: %2").arg(updateChannel == UpdateCheck::UpdateChannel::Stable ? tr("stable") : tr("beta"), currentVersion);
QString currentVersionString;
if (updateChannel == UpdateCheck::UpdateChannel::Stable)
currentVersionString = QString("v%1").arg(currentVersion);
else
currentVersionString = QString("%1 %2").arg(tr("build"), currentVersion);
const auto statusText = tr("You are running the latest %1 version of 86Box: %2").arg(updateChannel == UpdateCheck::UpdateChannel::Stable ? tr("stable") : tr("beta"), currentVersionString);
ui->statusLabel->setText(statusText);
ui->buttonBox->setStandardButtons(QDialogButtonBox::Ok);
}