Skip to content

Commit

Permalink
Qt-GUI: Cleaning the option menu (#443)
Browse files Browse the repository at this point in the history
  • Loading branch information
Xphalnos authored Aug 15, 2024
1 parent d45563f commit 0b1d783
Show file tree
Hide file tree
Showing 2 changed files with 415 additions and 450 deletions.
39 changes: 18 additions & 21 deletions src/qt_gui/settings_dialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -39,13 +39,28 @@ SettingsDialog::SettingsDialog(std::span<const QString> physical_devices, QWidge
ui->buttonBox->button(QDialogButtonBox::StandardButton::Close)->setFocus();
});

// EMULATOR TAB
// GENERAL TAB
{
connect(ui->userNameLineEdit, &QLineEdit::textChanged, this,
[](const QString& text) { Config::setUserName(text.toStdString()); });

connect(ui->consoleLanguageComboBox, &QComboBox::currentIndexChanged, this,
[](int index) { Config::setLanguage(index); });

connect(ui->userNameLineEdit, &QLineEdit::textChanged, this,
[](const QString& text) { Config::setUserName(text.toStdString()); });
connect(ui->fullscreenCheckBox, &QCheckBox::stateChanged, this,
[](int val) { Config::setFullscreenMode(val); });

connect(ui->showSplashCheckBox, &QCheckBox::stateChanged, this,
[](int val) { Config::setShowSplash(val); });

connect(ui->ps4proCheckBox, &QCheckBox::stateChanged, this,
[](int val) { Config::setNeoMode(val); });

connect(ui->logTypeComboBox, &QComboBox::currentTextChanged, this,
[](const QString& text) { Config::setLogType(text.toStdString()); });

connect(ui->logFilterLineEdit, &QLineEdit::textChanged, this,
[](const QString& text) { Config::setLogFilter(text.toStdString()); });
}

// GPU TAB
Expand Down Expand Up @@ -74,24 +89,6 @@ SettingsDialog::SettingsDialog(std::span<const QString> physical_devices, QWidge
[](int val) { Config::setDumpPM4(val); });
}

// GENERAL TAB
{
connect(ui->fullscreenCheckBox, &QCheckBox::stateChanged, this,
[](int val) { Config::setFullscreenMode(val); });

connect(ui->showSplashCheckBox, &QCheckBox::stateChanged, this,
[](int val) { Config::setShowSplash(val); });

connect(ui->ps4proCheckBox, &QCheckBox::stateChanged, this,
[](int val) { Config::setNeoMode(val); });

connect(ui->logTypeComboBox, &QComboBox::currentTextChanged, this,
[](const QString& text) { Config::setLogType(text.toStdString()); });

connect(ui->logFilterLineEdit, &QLineEdit::textChanged, this,
[](const QString& text) { Config::setLogFilter(text.toStdString()); });
}

// DEBUG TAB
{
connect(ui->debugDump, &QCheckBox::stateChanged, this,
Expand Down
Loading

0 comments on commit 0b1d783

Please sign in to comment.