summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNarr the Reg <juangerman-13@hotmail.com>2023-11-10 03:30:00 +0100
committerNarr the Reg <juangerman-13@hotmail.com>2023-11-10 17:22:04 +0100
commit9e331f9957bbc7aec82cd8f96c67373e115bcd68 (patch)
treee649eab7f50bd41958c1694a6b090a74e9b445e3
parentyuzu: Save mute when in background setting (diff)
downloadyuzu-9e331f9957bbc7aec82cd8f96c67373e115bcd68.tar
yuzu-9e331f9957bbc7aec82cd8f96c67373e115bcd68.tar.gz
yuzu-9e331f9957bbc7aec82cd8f96c67373e115bcd68.tar.bz2
yuzu-9e331f9957bbc7aec82cd8f96c67373e115bcd68.tar.lz
yuzu-9e331f9957bbc7aec82cd8f96c67373e115bcd68.tar.xz
yuzu-9e331f9957bbc7aec82cd8f96c67373e115bcd68.tar.zst
yuzu-9e331f9957bbc7aec82cd8f96c67373e115bcd68.zip
-rw-r--r--src/common/settings.h2
-rw-r--r--src/yuzu/main.cpp12
2 files changed, 7 insertions, 7 deletions
diff --git a/src/common/settings.h b/src/common/settings.h
index 9317075f7..e899f1ae6 100644
--- a/src/common/settings.h
+++ b/src/common/settings.h
@@ -153,7 +153,7 @@ struct Values {
true,
true};
Setting<bool, false> audio_muted{
- linkage, false, "audio_muted", Category::Audio, Specialization::Default, false, true};
+ linkage, false, "audio_muted", Category::Audio, Specialization::Default, true, true};
Setting<bool, false> dump_audio_commands{
linkage, false, "dump_audio_commands", Category::Audio, Specialization::Default, false};
diff --git a/src/yuzu/main.cpp b/src/yuzu/main.cpp
index 91aba118a..1bf173efb 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());