aboutsummaryrefslogtreecommitdiff
path: root/src/yuzu/configuration/configure_cpu.cpp
diff options
context:
space:
mode:
authorlat9nq <22451773+lat9nq@users.noreply.github.com>2023-06-10 16:40:38 -0400
committerlat9nq <22451773+lat9nq@users.noreply.github.com>2023-07-21 10:56:54 -0400
commit79024bb9554ba676a654ff76335008e37181be1c (patch)
treea808269c725a2d3c8d310503133213e528dd66be /src/yuzu/configuration/configure_cpu.cpp
parentc5f8b909ecee8d58b86b3e70e5e6defe56d4780c (diff)
FIXME configuration: Avoid unnecessary allocations
ConfigurationShared::Widget needs to be created with a builder. This would avoid some duplicated code.
Diffstat (limited to 'src/yuzu/configuration/configure_cpu.cpp')
-rw-r--r--src/yuzu/configuration/configure_cpu.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/yuzu/configuration/configure_cpu.cpp b/src/yuzu/configuration/configure_cpu.cpp
index 3f321039f6..f4bec11556 100644
--- a/src/yuzu/configuration/configure_cpu.cpp
+++ b/src/yuzu/configuration/configure_cpu.cpp
@@ -50,6 +50,10 @@ void ConfigureCpu::Setup() {
push(Settings::Category::CpuUnsafe);
for (const auto setting : settings) {
+ if (!Settings::IsConfiguringGlobal() && !setting->Switchable()) {
+ continue;
+ }
+
auto* widget = new ConfigurationShared::Widget(setting, translations, combobox_translations,
this, runtime_lock, apply_funcs);