カスタムリストビューを取得するためにカーソルアダプタを使用しています.2つのxmlファイルがあります。
a.xmlにLinearlayoutはListview
y.xmlにはLinearlayout2つありTextviewます。
リストビューが表示されているときに選択できませんsetOnItemClickListener。リストビューからアイテムを選択するために使用しています。
android:focusable="false私はこれを検索しようとしましたが、それらの多くが同じ問題を抱えていることがわかりました。これをxmlのtextviewとプログラムの両方に適用してみました。
この問題の修正は何ですか?
a.xml
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/scroller"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:fillViewport="true" >
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="vertical" >
<TextView
android:id="@+id/text"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
/>
<TextView
android:id="@+id/text1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
/>
</LinearLayout>
</ScrollView>
y.xml
LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="vertical" >
<ListView
android:id="@+id/list"
android:layout_width="fill_parent"
android:layout_height="wrap_content" >
</ListView>
</LinearLayout>