summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDentomologist <dentomologist@gmail.com>2026-03-04 18:31:55 -0800
committerGitHub <noreply@github.com>2026-03-04 18:31:55 -0800
commit49d5299f1e41930d31cc83dc28c4c583589ff674 (patch)
tree9f5c51dc553db43b1b88245c5f503c1ed58350b0
parent239c4e444c82c811eb321481aa26fe3a94d3b3c5 (diff)
parentd25ef67d6fc62eb96e0df8241d35a35e8ef38902 (diff)
Merge pull request #14438 from JosJuice/save-on-settings-close
DolphinQt: Save when closing settings window
-rw-r--r--Source/Core/DolphinQt/Config/SettingsWindow.cpp5
-rw-r--r--Source/Core/DolphinQt/Config/SettingsWindow.h2
-rw-r--r--Source/Core/DolphinQt/Settings/GeneralPane.cpp5
-rw-r--r--Source/Core/DolphinQt/Settings/WiiPane.cpp1
4 files changed, 7 insertions, 6 deletions
diff --git a/Source/Core/DolphinQt/Config/SettingsWindow.cpp b/Source/Core/DolphinQt/Config/SettingsWindow.cpp
index e80b1fa7ff..283cd3786e 100644
--- a/Source/Core/DolphinQt/Config/SettingsWindow.cpp
+++ b/Source/Core/DolphinQt/Config/SettingsWindow.cpp
@@ -210,3 +210,8 @@ void SettingsWindow::SelectPane(SettingsWindowPaneIndex index)
{
ActivatePane(std::to_underlying(index));
}
+
+void SettingsWindow::closeEvent(QCloseEvent*)
+{
+ Config::Save();
+}
diff --git a/Source/Core/DolphinQt/Config/SettingsWindow.h b/Source/Core/DolphinQt/Config/SettingsWindow.h
index 3874c75ae0..c27d6e919d 100644
--- a/Source/Core/DolphinQt/Config/SettingsWindow.h
+++ b/Source/Core/DolphinQt/Config/SettingsWindow.h
@@ -60,4 +60,6 @@ public:
explicit SettingsWindow(MainWindow* parent);
void SelectPane(SettingsWindowPaneIndex);
+
+ void closeEvent(QCloseEvent* event) override;
};
diff --git a/Source/Core/DolphinQt/Settings/GeneralPane.cpp b/Source/Core/DolphinQt/Settings/GeneralPane.cpp
index 802292f688..7561aaa939 100644
--- a/Source/Core/DolphinQt/Settings/GeneralPane.cpp
+++ b/Source/Core/DolphinQt/Settings/GeneralPane.cpp
@@ -16,7 +16,6 @@
#include "Core/AchievementManager.h"
#include "Core/Config/MainSettings.h"
#include "Core/Config/UISettings.h"
-#include "Core/ConfigManager.h"
#include "Core/Core.h"
#include "Core/DolphinAnalytics.h"
#include "Core/System.h"
@@ -117,7 +116,6 @@ void GeneralPane::ConnectLayout()
connect(m_combobox_speedlimit, &QComboBox::currentIndexChanged, [this] {
Config::SetBaseOrCurrent(Config::MAIN_EMULATION_SPEED,
m_combobox_speedlimit->currentIndex() * 0.1f);
- Config::Save();
});
connect(m_combobox_fallback_region, &QComboBox::currentIndexChanged, this,
@@ -339,7 +337,6 @@ void GeneralPane::OnSaveConfig()
{
Config::ConfigChangeCallbackGuard config_guard;
- auto& settings = SConfig::GetInstance();
if (AutoUpdateChecker::SystemSupportsAutoUpdates())
{
Settings::Instance().SetAutoUpdateTrack(
@@ -356,8 +353,6 @@ void GeneralPane::OnSaveConfig()
#endif
Settings::Instance().SetFallbackRegion(
UpdateFallbackRegionFromIndex(m_combobox_fallback_region->currentIndex()));
-
- settings.SaveSettings();
}
#if defined(USE_ANALYTICS) && USE_ANALYTICS
diff --git a/Source/Core/DolphinQt/Settings/WiiPane.cpp b/Source/Core/DolphinQt/Settings/WiiPane.cpp
index 19d54ca50c..bab5b9b540 100644
--- a/Source/Core/DolphinQt/Settings/WiiPane.cpp
+++ b/Source/Core/DolphinQt/Settings/WiiPane.cpp
@@ -369,7 +369,6 @@ void WiiPane::OnUSBWhitelistAddButton()
}
whitelist.emplace(*usb_device);
Config::SetUSBDeviceWhitelist(whitelist);
- Config::Save();
PopulateUSBPassthroughListWidget();
}