mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-09-21 00:55:09 -07:00
[Dialogs] Focus login after selecting server, center update message box (#7080)
* [ConnectDialog] Focus login field after selecting a server (#3346) Took 12 minutes * [UpdateDialog] Center update message boxes over the main window (#3538) --------- Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
This commit is contained in:
parent
c7ab75c332
commit
10b99a7415
2 changed files with 4 additions and 3 deletions
|
|
@ -271,6 +271,7 @@ void DlgConnect::updateDisplayInfo(const QString &saveName)
|
||||||
hostEdit->setText(_data.at(1));
|
hostEdit->setText(_data.at(1));
|
||||||
portEdit->setText(_data.at(2));
|
portEdit->setText(_data.at(2));
|
||||||
playernameEdit->setText(_data.at(3));
|
playernameEdit->setText(_data.at(3));
|
||||||
|
playernameEdit->setFocus();
|
||||||
savePasswordCheckBox->setChecked(savePasswordStatus);
|
savePasswordCheckBox->setChecked(savePasswordStatus);
|
||||||
|
|
||||||
if (savePasswordStatus) {
|
if (savePasswordStatus) {
|
||||||
|
|
|
||||||
|
|
@ -134,7 +134,7 @@ void DlgUpdate::finishedUpdateCheck(bool needToUpdate, bool isCompatible, Releas
|
||||||
// If there's no need to update, tell them that. However we still allow them to run the
|
// If there's no need to update, tell them that. However we still allow them to run the
|
||||||
// downloader themselves if there's a compatible build
|
// downloader themselves if there's a compatible build
|
||||||
QMessageBox::information(
|
QMessageBox::information(
|
||||||
this, tr("No Update Available"),
|
window(), tr("No Update Available"),
|
||||||
tr("Cockatrice is up to date!") + "<br><br>" +
|
tr("Cockatrice is up to date!") + "<br><br>" +
|
||||||
tr("You are already running the latest version available in the chosen release channel.") + "<br>" +
|
tr("You are already running the latest version available in the chosen release channel.") + "<br>" +
|
||||||
"<b>" + tr("Current version") + QString(":</b> %1<br>").arg(VERSION_STRING) + "<b>" +
|
"<b>" + tr("Current version") + QString(":</b> %1<br>").arg(VERSION_STRING) + "<b>" +
|
||||||
|
|
@ -147,7 +147,7 @@ void DlgUpdate::finishedUpdateCheck(bool needToUpdate, bool isCompatible, Releas
|
||||||
if (isCompatible) {
|
if (isCompatible) {
|
||||||
int reply;
|
int reply;
|
||||||
reply = QMessageBox::question(
|
reply = QMessageBox::question(
|
||||||
this, tr("Update Available"),
|
window(), tr("Update Available"),
|
||||||
tr("A new version of Cockatrice is available!") + "<br><br>" + "<b>" + tr("New version") +
|
tr("A new version of Cockatrice is available!") + "<br><br>" + "<b>" + tr("New version") +
|
||||||
QString(":</b> %1<br>").arg(release->getName()) + "<b>" + tr("Released") +
|
QString(":</b> %1<br>").arg(release->getName()) + "<b>" + tr("Released") +
|
||||||
QString(":</b> %1 (<a href=\"%2\">").arg(publishDate, release->getDescriptionUrl()) + tr("Changelog") +
|
QString(":</b> %1 (<a href=\"%2\">").arg(publishDate, release->getDescriptionUrl()) + tr("Changelog") +
|
||||||
|
|
@ -161,7 +161,7 @@ void DlgUpdate::finishedUpdateCheck(bool needToUpdate, bool isCompatible, Releas
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
QMessageBox::information(
|
QMessageBox::information(
|
||||||
this, tr("Update Available"),
|
window(), tr("Update Available"),
|
||||||
tr("A new version of Cockatrice is available!") + "<br><br>" + "<b>" + tr("New version") +
|
tr("A new version of Cockatrice is available!") + "<br><br>" + "<b>" + tr("New version") +
|
||||||
QString(":</b> %1<br>").arg(release->getName()) + "<b>" + tr("Released") +
|
QString(":</b> %1<br>").arg(release->getName()) + "<b>" + tr("Released") +
|
||||||
QString(":</b> %1 (<a href=\"%2\">").arg(publishDate, release->getDescriptionUrl()) + tr("Changelog") +
|
QString(":</b> %1 (<a href=\"%2\">").arg(publishDate, release->getDescriptionUrl()) + tr("Changelog") +
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue