summaryrefslogtreecommitdiff
path: root/src/yuzu/configuration/configure_general.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/yuzu/configuration/configure_general.cpp')
-rw-r--r--src/yuzu/configuration/configure_general.cpp17
1 files changed, 8 insertions, 9 deletions
diff --git a/src/yuzu/configuration/configure_general.cpp b/src/yuzu/configuration/configure_general.cpp
index 06d368dfcb..10bcd650ea 100644
--- a/src/yuzu/configuration/configure_general.cpp
+++ b/src/yuzu/configuration/configure_general.cpp
@@ -6,7 +6,7 @@
#include "core/settings.h"
#include "ui_configure_general.h"
#include "yuzu/configuration/configure_general.h"
-#include "yuzu/ui_settings.h"
+#include "yuzu/uisettings.h"
ConfigureGeneral::ConfigureGeneral(QWidget* parent)
: QWidget(parent), ui(new Ui::ConfigureGeneral) {
@@ -20,30 +20,29 @@ ConfigureGeneral::ConfigureGeneral(QWidget* parent)
SetConfiguration();
- connect(ui->toggle_deepscan, &QCheckBox::stateChanged, this,
- [] { UISettings::values.is_game_list_reload_pending.exchange(true); });
-
- ui->use_cpu_jit->setEnabled(!Core::System::GetInstance().IsPoweredOn());
+ connect(ui->toggle_frame_limit, &QCheckBox::toggled, ui->frame_limit, &QSpinBox::setEnabled);
}
ConfigureGeneral::~ConfigureGeneral() = default;
void ConfigureGeneral::SetConfiguration() {
- ui->toggle_deepscan->setChecked(UISettings::values.game_directory_deepscan);
ui->toggle_check_exit->setChecked(UISettings::values.confirm_before_closing);
ui->toggle_user_on_boot->setChecked(UISettings::values.select_user_on_boot);
ui->theme_combobox->setCurrentIndex(ui->theme_combobox->findData(UISettings::values.theme));
- ui->use_cpu_jit->setChecked(Settings::values.use_cpu_jit);
+
+ ui->toggle_frame_limit->setChecked(Settings::values.use_frame_limit);
+ ui->frame_limit->setEnabled(ui->toggle_frame_limit->isChecked());
+ ui->frame_limit->setValue(Settings::values.frame_limit);
}
void ConfigureGeneral::ApplyConfiguration() {
- UISettings::values.game_directory_deepscan = ui->toggle_deepscan->isChecked();
UISettings::values.confirm_before_closing = ui->toggle_check_exit->isChecked();
UISettings::values.select_user_on_boot = ui->toggle_user_on_boot->isChecked();
UISettings::values.theme =
ui->theme_combobox->itemData(ui->theme_combobox->currentIndex()).toString();
- Settings::values.use_cpu_jit = ui->use_cpu_jit->isChecked();
+ Settings::values.use_frame_limit = ui->toggle_frame_limit->isChecked();
+ Settings::values.frame_limit = ui->frame_limit->value();
}
void ConfigureGeneral::changeEvent(QEvent* event) {