mirror of
https://github.com/topjohnwu/Magisk.git
synced 2025-12-31 07:36:47 +00:00
Added entry for safetynet attestation
This commit is contained in:
@@ -6,6 +6,7 @@ import android.os.Build
|
||||
import com.topjohnwu.magisk.ClassMap
|
||||
import com.topjohnwu.magisk.Config
|
||||
import com.topjohnwu.magisk.Const
|
||||
import com.topjohnwu.magisk.redesign.safetynet.SafetynetFragment
|
||||
import com.topjohnwu.magisk.ui.MainActivity
|
||||
import com.topjohnwu.magisk.ui.hide.MagiskHideFragment
|
||||
import com.topjohnwu.magisk.ui.home.HomeFragment
|
||||
@@ -70,6 +71,10 @@ object Navigation {
|
||||
}
|
||||
}
|
||||
|
||||
fun safetynet() = MagiskNavigationEvent {
|
||||
navDirections { destination = SafetynetFragment::class }
|
||||
}
|
||||
|
||||
fun log() = MagiskNavigationEvent {
|
||||
navDirections {
|
||||
destination = when {
|
||||
|
||||
@@ -10,4 +10,9 @@ class SafetynetFragment : CompatFragment<SafetynetViewModel, FragmentSafetynetMd
|
||||
override val layoutRes = R.layout.fragment_safetynet_md2
|
||||
override val viewModel by viewModel<SafetynetViewModel>()
|
||||
|
||||
override fun onStart() {
|
||||
super.onStart()
|
||||
activity.setTitle(R.string.safetyNet)
|
||||
}
|
||||
|
||||
}
|
||||
@@ -66,6 +66,7 @@ class SuperuserViewModel(
|
||||
|
||||
// ---
|
||||
|
||||
fun safetynetPressed() = Navigation.safetynet().publish()
|
||||
fun hidePressed() = Navigation.hide().publish()
|
||||
|
||||
fun deletePressed(item: PolicyRvItem) {
|
||||
|
||||
Reference in New Issue
Block a user