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
EventSystem下面已经挂载WXTouchInputOverride脚本,但是依旧触发requestSubscribeSystemMessage:fail require user interaction (only in touchend event)报错。
Unity2022.3.38, WX-SDK: 202504080206
The text was updated successfully, but these errors were encountered:
看了下WXTouchInputOverride.OnWxTouchEnd函数的实现 int clickListenerCount = button.onClick.GetPersistentEventCount(); if (clickListenerCount > 0) { button.onClick.SetPersistentListenerState(0, UnityEventCallState.EditorAndRuntime); button.onClick.Invoke(); button.onClick.SetPersistentListenerState(0, UnityEventCallState.Off); } 看起来运行时注册的onclick事件不会在OnWxTouchEnd中触发,编辑器上在button的onclick上手动挂载事件,可以解决问题。
int clickListenerCount = button.onClick.GetPersistentEventCount(); if (clickListenerCount > 0) { button.onClick.SetPersistentListenerState(0, UnityEventCallState.EditorAndRuntime); button.onClick.Invoke(); button.onClick.SetPersistentListenerState(0, UnityEventCallState.Off); }
Sorry, something went wrong.
No branches or pull requests
描述Bug
EventSystem下面已经挂载WXTouchInputOverride脚本,但是依旧触发requestSubscribeSystemMessage:fail require user interaction (only in touchend event)报错。
运行环境
The text was updated successfully, but these errors were encountered: