summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorlat9nq <lat9nq@gmail.com>2021-05-20 07:11:56 +0200
committerGitHub <noreply@github.com>2021-05-20 07:11:56 +0200
commit5153d5387aa8946af0e885596c42d05001422d42 (patch)
treebb10057e160742055111b2aee6cb4b392678f818
parentconfiguration_shared: Drop unused function and template another (diff)
downloadyuzu-5153d5387aa8946af0e885596c42d05001422d42.tar
yuzu-5153d5387aa8946af0e885596c42d05001422d42.tar.gz
yuzu-5153d5387aa8946af0e885596c42d05001422d42.tar.bz2
yuzu-5153d5387aa8946af0e885596c42d05001422d42.tar.lz
yuzu-5153d5387aa8946af0e885596c42d05001422d42.tar.xz
yuzu-5153d5387aa8946af0e885596c42d05001422d42.tar.zst
yuzu-5153d5387aa8946af0e885596c42d05001422d42.zip
-rw-r--r--src/yuzu/configuration/configure_cpu.cpp11
1 files changed, 4 insertions, 7 deletions
diff --git a/src/yuzu/configuration/configure_cpu.cpp b/src/yuzu/configuration/configure_cpu.cpp
index 901e54e0d..525c42ff0 100644
--- a/src/yuzu/configuration/configure_cpu.cpp
+++ b/src/yuzu/configuration/configure_cpu.cpp
@@ -67,14 +67,11 @@ void ConfigureCpu::AccuracyUpdated(int index) {
}
void ConfigureCpu::UpdateGroup(int index) {
- if (Settings::IsConfiguringGlobal()) {
- ui->unsafe_group->setVisible(static_cast<Settings::CPUAccuracy>(index) ==
- Settings::CPUAccuracy::Unsafe);
- } else {
- ui->unsafe_group->setVisible(
- static_cast<Settings::CPUAccuracy>(index - ConfigurationShared::USE_GLOBAL_OFFSET) ==
- Settings::CPUAccuracy::Unsafe);
+ if (!Settings::IsConfiguringGlobal()) {
+ index -= ConfigurationShared::USE_GLOBAL_OFFSET;
}
+ const auto accuracy = static_cast<Settings::CPUAccuracy>(index);
+ ui->unsafe_group->setVisible(accuracy == Settings::CPUAccuracy::Unsafe);
}
void ConfigureCpu::ApplyConfiguration() {