Skip to content

Commit

Permalink
refine find method
Browse files Browse the repository at this point in the history
  • Loading branch information
5ec1cff committed Dec 22, 2024
1 parent 42df7ab commit 1dd4725
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions app/src/main/java/five/ec1cff/myinjector/BaiduIMEHandler.kt
Original file line number Diff line number Diff line change
Expand Up @@ -94,11 +94,18 @@ class BaiduIMEHandler : IXposedHookLoadPackage {
Log.d(TAG, "prepare: start deobf")
System.loadLibrary("dexkit")
val bridge = DexKitBridge.create(lpparam.classLoader, true)
val showMethod = bridge.findMethod {
val showMethod = bridge.findClass {
matcher {
declaredClass {
usingStrings("android.permission.READ_CONTACTS", "layout_inflater")
usingStrings("android.permission.READ_CONTACTS", "layout_inflater")
addMethod {
addInvoke {
name = "getWindowToken"
declaredClass = "android.view.View"
}
}
}
}.findMethod {
matcher {
addInvoke {
name = "getWindowToken"
declaredClass = "android.view.View"
Expand Down

0 comments on commit 1dd4725

Please sign in to comment.