Skip to content

Commit e6edf5b

Browse files
committed
feat: action log support Shizuku, update Shizuku mode description (full features)
1 parent 55d0f23 commit e6edf5b

File tree

2 files changed

+10
-5
lines changed

2 files changed

+10
-5
lines changed

app/src/main/java/com/appcontrolx/ui/ActionLogBottomSheet.kt

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -55,10 +55,15 @@ class ActionLogBottomSheet : BottomSheetDialogFragment() {
5555

5656
private fun setupExecutor() {
5757
val mode = PermissionBridge(requireContext()).detectMode()
58-
if (mode is ExecutionMode.Root) {
59-
val executor = RootExecutor()
60-
policyManager = BatteryPolicyManager(executor)
61-
rollbackManager = RollbackManager(requireContext(), executor)
58+
val executor: com.appcontrolx.executor.CommandExecutor? = when (mode) {
59+
is ExecutionMode.Root -> RootExecutor()
60+
is ExecutionMode.Shizuku -> com.appcontrolx.executor.ShizukuExecutor()
61+
else -> null
62+
}
63+
64+
executor?.let {
65+
policyManager = BatteryPolicyManager(it)
66+
rollbackManager = RollbackManager(requireContext(), it)
6267
}
6368
}
6469

app/src/main/res/values/strings.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
<string name="mode_root">Root Mode</string>
2121
<string name="mode_root_desc">Full system access. Can freeze, uninstall, and control any app. Requires rooted device with Magisk or similar.</string>
2222
<string name="mode_shizuku">Shizuku Mode</string>
23-
<string name="mode_shizuku_desc">ADB-level access without root. Requires Shizuku app running. Some features may be limited.</string>
23+
<string name="mode_shizuku_desc">Full access without root. All features available including freeze, restrict, and uninstall. Requires Shizuku app running.</string>
2424
<string name="mode_view_only">View-Only Mode</string>
2525
<string name="mode_view_only_desc">Browse installed apps only. No control features available. Good for exploring the app.</string>
2626

0 commit comments

Comments
 (0)