1
0
mirror of https://github.com/vcmi/vcmi.git synced 2024-11-28 08:48:48 +02:00

disable some launcher settings that are useless on iOS

kambala-decapitator/vcmi#17
This commit is contained in:
Andrey Filipenkov 2021-04-21 09:55:13 +03:00
parent 13d0de17cd
commit 6652e656c3

View File

@ -67,9 +67,17 @@ void CSettingsView::loadSettings()
int resIndex = ui->comboBoxResolution->findText(QString("%1x%2").arg(resX).arg(resY));
ui->comboBoxResolution->setCurrentIndex(resIndex);
ui->comboBoxFullScreen->setCurrentIndex(settings["video"]["fullscreen"].Bool());
ui->comboBoxShowIntro->setCurrentIndex(settings["video"]["showIntro"].Bool());
#ifdef Q_OS_IOS
ui->comboBoxFullScreen->setCurrentIndex(true);
ui->checkBoxFullScreen->setChecked(false);
for (auto widget : std::initializer_list<QWidget *>{ui->comboBoxFullScreen, ui->checkBoxFullScreen})
widget->setDisabled(true);
#else
ui->comboBoxFullScreen->setCurrentIndex(settings["video"]["fullscreen"].Bool());
ui->checkBoxFullScreen->setChecked(settings["video"]["realFullscreen"].Bool());
#endif
int friendlyAIIndex = ui->comboBoxFriendlyAI->findText(QString::fromUtf8(settings["server"]["friendlyAI"].String().c_str()));
int neutralAIIndex = ui->comboBoxNeutralAI->findText(QString::fromUtf8(settings["server"]["neutralAI"].String().c_str()));