mirror of
https://github.com/PrismLauncher/PrismLauncher.git
synced 2025-09-15 23:16:26 -04:00
Fixes more of the OM (Offline Mode) breaking codes
This commit is contained in:
parent
1750bf5d45
commit
c5005b9024
@ -136,15 +136,24 @@ bool LaunchController::askPlayDemo()
|
|||||||
QMessageBox box(m_parentWidget);
|
QMessageBox box(m_parentWidget);
|
||||||
box.setWindowTitle(tr("Play demo?"));
|
box.setWindowTitle(tr("Play demo?"));
|
||||||
box.setText(
|
box.setText(
|
||||||
tr("This account does not own Minecraft.\nYou need to purchase the game first to play it.\n\nDo you want to play "
|
tr("This account does not own Minecraft.\n"
|
||||||
"the demo?"));
|
"You need to purchase the game first to play it.\n\n"
|
||||||
|
"Do you want to play the demo?"));
|
||||||
box.setIcon(QMessageBox::Warning);
|
box.setIcon(QMessageBox::Warning);
|
||||||
|
|
||||||
auto demoButton = box.addButton(tr("Play Demo"), QMessageBox::ButtonRole::YesRole);
|
auto demoButton = box.addButton(tr("Play Demo"), QMessageBox::ButtonRole::YesRole);
|
||||||
auto cancelButton = box.addButton(tr("Cancel"), QMessageBox::ButtonRole::NoRole);
|
auto continueButton = box.addButton(tr("Continue Anyway"), QMessageBox::ButtonRole::AcceptRole);
|
||||||
box.setDefaultButton(cancelButton);
|
auto cancelButton = box.addButton(tr("Cancel"), QMessageBox::ButtonRole::RejectRole);
|
||||||
|
|
||||||
box.exec();
|
box.exec();
|
||||||
return box.clickedButton() == demoButton;
|
|
||||||
|
if (box.clickedButton() == demoButton) {
|
||||||
|
return true;
|
||||||
|
} else if (box.clickedButton() == continueButton) {
|
||||||
|
return true;
|
||||||
|
} else {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
QString LaunchController::askOfflineName(QString playerName, bool demo, bool& ok)
|
QString LaunchController::askOfflineName(QString playerName, bool demo, bool& ok)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user