Kaynağa Gözat

Launcher setting: Disable spinBoxFramerateLimit if VSync is enabled

Alexander Wilms 2 yıl önce
ebeveyn
işleme
e33127a1f7
1 değiştirilmiş dosya ile 2 ekleme ve 0 silme
  1. 2 0
      launcher/settingsView/csettingsview_moc.cpp

+ 2 - 0
launcher/settingsView/csettingsview_moc.cpp

@@ -83,6 +83,7 @@ void CSettingsView::loadSettings()
 
 	ui->spinBoxInterfaceScaling->setValue(settings["video"]["resolution"]["scaling"].Float());
 	ui->spinBoxFramerateLimit->setValue(settings["video"]["targetfps"].Float());
+	ui->spinBoxFramerateLimit->setDisabled(settings["video"]["vsync"].Bool());
 	ui->checkBoxVSync->setChecked(settings["video"]["vsync"].Bool());
 	ui->spinBoxReservedArea->setValue(std::round(settings["video"]["reservedWidth"].Float() * 100));
 
@@ -499,6 +500,7 @@ void CSettingsView::on_checkBoxVSync_stateChanged(int arg1)
 {
 	Settings node = settings.write["video"]["vsync"];
 	node->Bool() = arg1;
+	ui->spinBoxFramerateLimit->setDisabled(settings["video"]["vsync"].Bool());
 }
 
 void CSettingsView::on_comboBoxEnemyPlayerAI_currentTextChanged(const QString &arg1)