diff --git a/app/src/main/java/cc/microblock/hook/ForceEnableMultiForward.kt b/app/src/main/java/cc/microblock/hook/ForceEnableMultiForward.kt index 95dde8884d..4eef82d51a 100644 --- a/app/src/main/java/cc/microblock/hook/ForceEnableMultiForward.kt +++ b/app/src/main/java/cc/microblock/hook/ForceEnableMultiForward.kt @@ -23,19 +23,16 @@ package cc.microblock.hook import android.view.View -import cc.hicore.hook.ReplyMsgWithImg +import android.widget.RelativeLayout +import cc.hicore.QApp.QAppUtils import cc.ioctl.util.HookUtils import cc.ioctl.util.Reflex -import com.github.kyuubiran.ezxhelper.utils.getObject -import de.robv.android.xposed.XC_MethodHook.MethodHookParam +import com.github.kyuubiran.ezxhelper.utils.getObjectAs import io.github.qauxv.base.annotation.FunctionHookEntry import io.github.qauxv.base.annotation.UiItemAgentEntry import io.github.qauxv.dsl.FunctionEntryRouter import io.github.qauxv.hook.CommonSwitchFunctionHook import io.github.qauxv.util.Initiator -import xyz.nextalone.util.get -import android.widget.RelativeLayout; -import com.github.kyuubiran.ezxhelper.utils.getObjectAs @FunctionHookEntry @UiItemAgentEntry @@ -55,4 +52,5 @@ object ForceEnableMultiForward : CommonSwitchFunctionHook() { return true; } + override val isAvailable = QAppUtils.isQQnt(); } diff --git a/app/src/main/java/cc/microblock/hook/Pangu.kt b/app/src/main/java/cc/microblock/hook/Pangu.kt index 1c42545643..eec5f89d71 100644 --- a/app/src/main/java/cc/microblock/hook/Pangu.kt +++ b/app/src/main/java/cc/microblock/hook/Pangu.kt @@ -22,6 +22,7 @@ package cc.microblock.hook +import cc.hicore.QApp.QAppUtils import com.github.kyuubiran.ezxhelper.utils.hookBefore import io.github.qauxv.base.annotation.FunctionHookEntry import io.github.qauxv.base.annotation.UiItemAgentEntry @@ -166,7 +167,7 @@ object SendPangu : CommonSwitchFunctionHook("sendMsgPangu",arrayOf(AIOTextElemen override val description = "自动在中英文间加上空格,以美化排版\n若消息以空格开头,则不会被 Pangu 化" override val uiItemLocation = FunctionEntryRouter.Locations.Simplify.CHAT_OTHER - + override val isAvailable = QAppUtils.isQQnt(); override fun initOnce(): Boolean { DexKit.requireMethodFromCache(AIOTextElementCtor) .hookBefore {