Fix auto-join getting stuck disabled
Signed-off-by: TheKodeToad <TheKodeToad@proton.me>
This commit is contained in:
@@ -224,7 +224,8 @@ void MinecraftSettingsWidget::loadSettings()
|
|||||||
m_ui->useZink->setChecked(settings->get("UseZink").toBool());
|
m_ui->useZink->setChecked(settings->get("UseZink").toBool());
|
||||||
|
|
||||||
if (m_instance != nullptr) {
|
if (m_instance != nullptr) {
|
||||||
m_ui->serverJoinGroupBox->setChecked(settings->get("JoinServerOnLaunch").toBool());
|
// HACK: if we change enable state of child widgets while it's unchecked this creates inconsistency
|
||||||
|
m_ui->serverJoinGroupBox->setChecked(true);
|
||||||
|
|
||||||
if (auto server = settings->get("JoinServerOnLaunchAddress").toString(); !server.isEmpty()) {
|
if (auto server = settings->get("JoinServerOnLaunchAddress").toString(); !server.isEmpty()) {
|
||||||
m_ui->serverJoinAddress->setText(server);
|
m_ui->serverJoinAddress->setText(server);
|
||||||
@@ -241,10 +242,12 @@ void MinecraftSettingsWidget::loadSettings()
|
|||||||
} else {
|
} else {
|
||||||
m_ui->serverJoinAddressButton->setChecked(true);
|
m_ui->serverJoinAddressButton->setChecked(true);
|
||||||
m_ui->worldJoinButton->setChecked(false);
|
m_ui->worldJoinButton->setChecked(false);
|
||||||
m_ui->serverJoinAddress->setEnabled(m_ui->serverJoinGroupBox->isChecked());
|
m_ui->serverJoinAddress->setEnabled(true);
|
||||||
m_ui->worldsCb->setEnabled(false);
|
m_ui->worldsCb->setEnabled(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
m_ui->serverJoinGroupBox->setChecked(settings->get("JoinServerOnLaunch").toBool());
|
||||||
|
|
||||||
m_ui->instanceAccountGroupBox->setChecked(settings->get("UseAccountForInstance").toBool());
|
m_ui->instanceAccountGroupBox->setChecked(settings->get("UseAccountForInstance").toBool());
|
||||||
updateAccountsMenu(*settings);
|
updateAccountsMenu(*settings);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user