We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
突然又发现了一个bug,before 和 after 的回调里替换 result 无效。
"com.android.systemui.qs.QSTileHost".hook { injectMember { method { name = "createTile"; param(StringClass) } beforeHook { if (args(0).string() == "nfc") { val tile = XposedHelpers.callMethod(instance, "createTile", "bt") result = tile } } } } }
效果:
无效
XposedHelpers.findAndHookMethod("com.android.systemui.qs.QSTileHost".toClass(), "createTile", String::class.java, object : XC_MethodHook() { override fun beforeHookedMethod(param: MethodHookParam) { super.beforeHookedMethod(param) if (param.args[0] == "nfc") { val tile = XposedHelpers.callMethod(param.thisObject, "createTile", "bt") param.result = tile } } })
有效
The text was updated successfully, but these errors were encountered:
错误的用法,你可以把 XposedHelpers 丢掉了
Sorry, something went wrong.
可是我用了 method.invoke(instance, "bt") 也是不行的
method.invoke(instance, "bt")
错误的用法,你可以把 XposedHelpers 丢掉了 可是我用了 method.invoke(instance, "bt") 也是不行的
用 callOriginal,因为不知道你是不是重新调用的原始方法。 这里不常回复,有问题请电报群反馈。
callOriginal
后期调整到 #33
No branches or pull requests
突然又发现了一个bug,before 和 after 的回调里替换 result 无效。
将状态栏的 NFC 磁贴 替换成 蓝牙
效果:
![86b5b1440dcbe68015b62465ed55797](https://user-images.githubusercontent.com/42611305/235353663-a7729e33-55f8-4fd6-a3ef-038ebf51551f.jpg)
无效效果:
![a7ed2e1678e59e26f5153927e257736](https://user-images.githubusercontent.com/42611305/235353867-bceeb207-f61c-452d-a41f-7ebe385c470c.jpg)
有效
The text was updated successfully, but these errors were encountered: