kernel: Allow to re-enable sucompat

This commit is contained in:
weishu
2025-02-16 21:33:26 +08:00
committed by rifsxd
parent d05d16c15d
commit 85866848ea
2 changed files with 37 additions and 110 deletions

View File

@@ -179,7 +179,6 @@ fun SettingScreen(navigator: DestinationsNavigator) {
title = stringResource(id = R.string.settings_disable_su),
summary = stringResource(id = R.string.settings_disable_su_summary),
checked = isSuDisabled,
enabled = !isSuDisabled // we can't re-enable su if it's disabled.
) { checked ->
val shouldEnable = !checked
if (Natives.setSuEnabled(shouldEnable)) {