Show confirmation dialog before restore app

This commit is contained in:
canyie
2022-01-21 01:02:55 -08:00
committed by John Wu
parent 47545b45b8
commit 454e5dfc5d
5 changed files with 28 additions and 1 deletions
@@ -20,6 +20,7 @@ import com.topjohnwu.magisk.events.AddHomeIconEvent
import com.topjohnwu.magisk.events.RecreateEvent
import com.topjohnwu.magisk.events.SnackbarEvent
import com.topjohnwu.magisk.events.dialog.BiometricEvent
import com.topjohnwu.magisk.events.dialog.RestoreAppDialog
import com.topjohnwu.magisk.ktx.activity
import com.topjohnwu.magisk.utils.Utils
import com.topjohnwu.superuser.Shell
@@ -104,7 +105,7 @@ class SettingsViewModel : BaseViewModel(), BaseSettingsItem.Callback {
is DenyListConfig ->
SettingsFragmentDirections.actionSettingsFragmentToDenyFragment().navigate()
is SystemlessHosts -> createHosts()
is Restore -> HideAPK.restore(view.activity)
is Restore -> RestoreAppDialog().publish()
is AddShortcut -> AddHomeIconEvent().publish()
else -> callback()
}