mirror of
https://github.com/PCSX2/pcsx2.git
synced 2025-12-16 04:08:48 +00:00
Achievements/Qt: Show success feedback on RetroAchievements login
This commit is contained in:
parent
a1485fb7cd
commit
db6792af2e
@ -127,7 +127,25 @@ void AchievementLoginDialog::processLoginResult(bool result, const QString& mess
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
done(0);
|
// Show success messagebox
|
||||||
|
const std::string username = Host::GetBaseStringSettingValue("Achievements", "Username");
|
||||||
|
QMessageBox::information(
|
||||||
|
this, tr("Login Successful"),
|
||||||
|
tr("Successfully logged in to RetroAchievements as %1.").arg(QString::fromStdString(username)));
|
||||||
|
|
||||||
|
m_ui.status->setText(tr("Successfully logged in as %1.").arg(QString::fromStdString(username)));
|
||||||
|
m_ui.status->setStyleSheet("color: green; font-weight: bold;");
|
||||||
|
|
||||||
|
disconnect(m_ui.buttonBox, &QDialogButtonBox::accepted, this, &AchievementLoginDialog::loginClicked);
|
||||||
|
|
||||||
|
m_login->setVisible(false);
|
||||||
|
QPushButton* dismissButton = m_ui.buttonBox->addButton(tr("&Dismiss"), QDialogButtonBox::AcceptRole);
|
||||||
|
dismissButton->setDefault(true);
|
||||||
|
dismissButton->setFocus();
|
||||||
|
|
||||||
|
connect(dismissButton, &QPushButton::clicked, this, [this]() { done(0); });
|
||||||
|
|
||||||
|
enableUI(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
void AchievementLoginDialog::connectUi()
|
void AchievementLoginDialog::connectUi()
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user