Fix ReLSPosed module not activated issue

This commit is contained in:
frknkrc44 2025-09-07 23:43:31 +03:00 • committed by Cuynu
commit 9f1dd0bb36
4 changed files with 2 additions and 17 deletions

View file

@ -1,8 +1,3 @@
# Xposed
-keepclassmembers class icu.nullptr.hidemyapplist.MyApp {
boolean isHooked;
}
# Enum class
-keepclassmembers,allowoptimization enum * {
public static **[] values();

View file

@ -17,10 +17,6 @@ import kotlin.system.exitProcess
lateinit var hmaApp: MyApp
class MyApp : Application() {
@JvmField
var isHooked = false
val globalScope = CoroutineScope(Dispatchers.Default)
val appIconLoader by lazy {
val iconSize = resources.getDimensionPixelSize(R.dimen.app_icon_size)

View file

@ -116,7 +116,6 @@ class HomeFragment : Fragment(R.layout.fragment_home) {
val serviceVersion = ServiceClient.serviceVersion
val color = when {
!hmaApp.isHooked -> getColor(R.color.gray)
serviceVersion == 0 -> getColor(R.color.invalid)
else -> themeColor(android.R.attr.colorPrimary)
}
@ -126,7 +125,7 @@ class HomeFragment : Fragment(R.layout.fragment_home) {
root.outlineAmbientShadowColor = color
root.outlineSpotShadowColor = color
if (hmaApp.isHooked) {
if (serviceVersion > 0) {
moduleStatusIcon.setImageResource(R.drawable.sentiment_calm_24px)
val versionNameSimple = BuildConfig.VERSION_NAME.substringBefore(".r")
moduleStatus.text =

View file

@ -23,12 +23,7 @@ class XposedEntry : IXposedHookZygoteInit, IXposedHookLoadPackage {
}
override fun handleLoadPackage(lpparam: XC_LoadPackage.LoadPackageParam) {
if (lpparam.packageName == Constants.APP_PACKAGE_NAME) {
EzXHelperInit.initHandleLoadPackage(lpparam)
hookAllConstructorAfter("icu.nullptr.hidemyapplist.MyApp") {
getFieldByDesc("Licu/nullptr/hidemyapplist/MyApp;->isHooked:Z").setBoolean(it.thisObject, true)
}
} else if (lpparam.packageName == "android") {
if (lpparam.packageName == "android") {
EzXHelperInit.initHandleLoadPackage(lpparam)
logI(TAG, "Hook entry")