From 166fed529a889049cb122a61d6800e3abaac9035 Mon Sep 17 00:00:00 2001 From: Dimitris Panokostas Date: Sun, 19 May 2024 19:06:54 +0200 Subject: [PATCH] enhancement: CPU panel had widgets that were not shown as disabled (#1326) The MMU and CPU Data Cache options were not visibly disabled as they should --- src/osdep/gui/PanelCPU.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/osdep/gui/PanelCPU.cpp b/src/osdep/gui/PanelCPU.cpp index c6bab0773..353239836 100644 --- a/src/osdep/gui/PanelCPU.cpp +++ b/src/osdep/gui/PanelCPU.cpp @@ -753,6 +753,9 @@ void RefreshPanelCPU() optFPU68882->setEnabled(changed_prefs.cpu_model < 68040 && (changed_prefs.cpu_model >= 68020 || !changed_prefs.cpu_compatible)); optFPUinternal->setEnabled(changed_prefs.cpu_model >= 68040); + optMMUEC->setEnabled(changed_prefs.cpu_model >= 68030 && changed_prefs.cachesize == 0); + optMMUEnabled->setEnabled(changed_prefs.cpu_model >= 68030 && changed_prefs.cachesize == 0); + // Set Values sldCpuSpeed->setValue(static_cast(changed_prefs.m68k_speed_throttle / 100)); auto cpu_speed_info = to_string(static_cast(changed_prefs.m68k_speed_throttle / 10)); @@ -762,6 +765,7 @@ void RefreshPanelCPU() chkCPUCompatible->setSelected(changed_prefs.cpu_compatible); chk24Bit->setSelected(changed_prefs.address_space_24); chkCpuDataCache->setSelected(changed_prefs.cpu_data_cache); + chkCpuDataCache->setEnabled(changed_prefs.cpu_model >= 68030 && changed_prefs.cachesize == 0 && changed_prefs.cpu_compatible); chkFPUStrict->setSelected(changed_prefs.fpu_strict); sldCpuIdle->setValue(changed_prefs.cpu_idle == 0 ? 0 : 12 - changed_prefs.cpu_idle / 15);