From 2bf227e5831be5313c8a10f24ed539144b33951f Mon Sep 17 00:00:00 2001 From: ztNFny Date: Sat, 26 Oct 2019 14:20:52 +0200 Subject: [PATCH 1/2] Android 10 compatibility. ActivityRecord class has moved from com.android.server.am to com.android.server.wm, realActivity variable was renamed to mActivityComponent --- src/com/germainz/activityforcenewtask/XposedMod.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/com/germainz/activityforcenewtask/XposedMod.java b/src/com/germainz/activityforcenewtask/XposedMod.java index 6b74318..7fda911 100644 --- a/src/com/germainz/activityforcenewtask/XposedMod.java +++ b/src/com/germainz/activityforcenewtask/XposedMod.java @@ -54,7 +54,7 @@ protected void afterHookedMethod(MethodHookParam param) throws Throwable { if (getIntField(param.thisObject, "launchedFromUid") == uid) return; - ComponentName componentName = (ComponentName) getObjectField(param.thisObject, "realActivity"); + ComponentName componentName = (ComponentName) getObjectField(param.thisObject, "mActivityComponent"); String componentNameString = componentName.flattenToString(); // Log if necessary. if (settingsHelper.isLogEnabled()) { @@ -81,7 +81,7 @@ protected void afterHookedMethod(MethodHookParam param) throws Throwable { } }; - Class ActivityRecord = findClass("com.android.server.am.ActivityRecord", lpparam.classLoader); + Class ActivityRecord = findClass("com.android.server.wm.ActivityRecord", lpparam.classLoader); XposedBridge.hookAllConstructors(ActivityRecord, hook); } From b07e7bd2965fd1f937879f6b26f4a573be94dae5 Mon Sep 17 00:00:00 2001 From: ztNFny Date: Sat, 26 Oct 2019 14:21:16 +0200 Subject: [PATCH 2/2] bump version to 2.1.4 --- AndroidManifest.xml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/AndroidManifest.xml b/AndroidManifest.xml index ef34cce..72d745f 100644 --- a/AndroidManifest.xml +++ b/AndroidManifest.xml @@ -1,11 +1,11 @@ + android:versionCode="25" + android:versionName="2.1.4"> + android:targetSdkVersion="28"/>