Android 父布局可以';无法检测单击WebView
我有这样的布局:Android 父布局可以';无法检测单击WebView,android,Android,我有这样的布局: <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="wrap_content" android:clickable="true" android
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:clickable="true"
android:focusable="true"
android:foreground="?selectableItemBackground"
android:orientation="horizontal">
<RadioButton
android:id="@+id/radioButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical" />
<WebView
android:id="@+id/webView"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical" />
</LinearLayout>
在我的RecyclerView
中,我想检测对该布局任何部分的点击,而不仅仅是RadioButton
。我遇到的问题是,我将click listener放在布局本身上,但当用户单击WebView
时,它不会检测到单击。我尝试过使WebView
不可点击和不可聚焦,但仍然不起作用