Click Listeners on Views Not Working
已完成I am experiencing an issue where none of the click listeners (e.g., for Button
, TextView
, etc.) in my application are functioning as expected. I suspect this may be caused by the SDK potentially interfering with or controlling certain parts of the view hierarchy, as I am following the provided code samples.
Could the SDK be intercepting or affecting touch events in a way that prevents click events from being propagated to child views? If so, are there any recommendations or adjustments I can make to ensure that click listeners work correctly across all views in my app?
Any insights or suggestions would be greatly appreciated!
-
When removing the SDK (the tried versions 5.8.0 and 5.10.0), my application works fine. However, when using 5.10.0, button clicks require additional logic, such as adding an `OnTouchListener` to handle touch events before the `OnClickListener` works properly:
```kotlin
binding.btnOpen.setOnTouchListener { ... }
```This issue affects all child views as well. It seems like the MSDK or the UXSDK might be interfering with event propagation.
-
The UXSDK library does not use view binding, so we are unsure if your changes are the cause of the listener failure. However, confirming this is easy; you just remove the UXSDK library, keep the Mobile SDK, and then run your application again. Currently, we have not received feedback from others regarding the same issue.
请先登录再写评论。
评论
5 条评论