mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-04-22 04:24:44 +00:00
combine functions
This commit is contained in:
parent
21bda6d43e
commit
8c256ca6b5
1 changed files with 8 additions and 11 deletions
|
@ -140,20 +140,17 @@ SettingsDialog::SettingsDialog(std::span<const QString> physical_devices, QWidge
|
|||
checkUpdate->exec();
|
||||
});
|
||||
|
||||
connect(ui->playBGMCheckBox, &QCheckBox::stateChanged, this,
|
||||
[](int val) { Config::setPlayBGM(val); });
|
||||
|
||||
connect(ui->BGMVolumeSlider, &QSlider::valueChanged, this,
|
||||
[](float val) { Config::setBGMvolume(val); });
|
||||
|
||||
connect(ui->BGMVolumeSlider, &QSlider::valueChanged, this,
|
||||
[](float val) { BackgroundMusicPlayer::getInstance().setVolume(val); });
|
||||
|
||||
connect(ui->playBGMCheckBox, &QCheckBox::stateChanged, this, [this](int state) {
|
||||
if (state == Qt::Unchecked) {
|
||||
connect(ui->playBGMCheckBox, &QCheckBox::stateChanged, this, [](int val) {
|
||||
Config::setPlayBGM(val);
|
||||
if (val == Qt::Unchecked) {
|
||||
BackgroundMusicPlayer::getInstance().stopMusic();
|
||||
}
|
||||
});
|
||||
|
||||
connect(ui->BGMVolumeSlider, &QSlider::valueChanged, this, [](float val) {
|
||||
Config::setBGMvolume(val);
|
||||
BackgroundMusicPlayer::getInstance().setVolume(val);
|
||||
});
|
||||
}
|
||||
|
||||
// GPU TAB
|
||||
|
|
Loading…
Add table
Reference in a new issue