rbutil: Fix bootloader uninstall availability.

The logic for disabling the uninstall button was wrong.

Change-Id: Icec4b70a7323bb6ae275e7b88fff414450ba4566
This commit is contained in:
Dominik Riebeling 2022-03-12 21:06:19 +01:00
parent 0ce287503c
commit 1ff11b627b

View file

@ -367,10 +367,10 @@ void RbUtilQt::updateDevice()
playerBuildInfo->value(PlayerBuildInfo::BootloaderMethod).toString());
/* Disable uninstallation actions if they are not supported. */
bool bootloaderUninstallable = !(bootloaderCapabilities & BootloaderInstallBase::Uninstall);
ui.labelRemoveBootloader->setEnabled(bootloaderUninstallable);
ui.buttonRemoveBootloader->setEnabled(bootloaderUninstallable);
ui.actionRemove_bootloader->setEnabled(bootloaderUninstallable);
bool canUninstall = (bootloaderCapabilities & BootloaderInstallBase::Uninstall);
ui.labelRemoveBootloader->setEnabled(canUninstall);
ui.buttonRemoveBootloader->setEnabled(canUninstall);
ui.actionRemove_bootloader->setEnabled(canUninstall);
/* Disable the whole tab widget if configuration is invalid */
bool configurationValid = !chkConfig(nullptr);