aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/yuzu/main.cpp
diff options
context:
space:
mode:
authorliamwhite <[email protected]>2023-11-13 09:13:12 -0500
committerGitHub <[email protected]>2023-11-13 09:13:12 -0500
commit247d66a680abd437164da98d2dcd1b39726faafc (patch)
treee4e1a688d4ef645b3c1faccd01204b7e9e44d16f /src/yuzu/main.cpp
parent0047d8a01ee7a6680c176022e5ab31a68bdeaf35 (diff)
parent9e331f9957bbc7aec82cd8f96c67373e115bcd68 (diff)
downloadyuzu-mainline-247d66a680abd437164da98d2dcd1b39726faafc.tar.gz
yuzu-mainline-247d66a680abd437164da98d2dcd1b39726faafc.zip
Merge pull request #11990 from german77/audio
yuzu: Save mute when in background setting
Diffstat (limited to 'src/yuzu/main.cpp')
-rw-r--r--src/yuzu/main.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/yuzu/main.cpp b/src/yuzu/main.cpp
index d2a054eaa..f077d7f9c 100644
--- a/src/yuzu/main.cpp
+++ b/src/yuzu/main.cpp
@@ -1064,12 +1064,6 @@ void GMainWindow::InitializeWidgets() {
volume_slider->setObjectName(QStringLiteral("volume_slider"));
volume_slider->setMaximum(200);
volume_slider->setPageStep(5);
- connect(volume_slider, &QSlider::valueChanged, this, [this](int percentage) {
- Settings::values.audio_muted = false;
- const auto volume = static_cast<u8>(percentage);
- Settings::values.volume.SetValue(volume);
- UpdateVolumeUI();
- });
volume_popup->layout()->addWidget(volume_slider);
volume_button = new VolumeButton();
@@ -1077,6 +1071,12 @@ void GMainWindow::InitializeWidgets() {
volume_button->setFocusPolicy(Qt::NoFocus);
volume_button->setCheckable(true);
UpdateVolumeUI();
+ connect(volume_slider, &QSlider::valueChanged, this, [this](int percentage) {
+ Settings::values.audio_muted = false;
+ const auto volume = static_cast<u8>(percentage);
+ Settings::values.volume.SetValue(volume);
+ UpdateVolumeUI();
+ });
connect(volume_button, &QPushButton::clicked, this, [&] {
UpdateVolumeUI();
volume_popup->setVisible(!volume_popup->isVisible());