私は2つのビューを持っています。画像とサブタイトルスクロールビュー内のリストビューはクリックできません
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="horizontal"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:background="@color/lightgray">
<ScrollView
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="fill_parent"
android:layout_height="wrap_content">
<TableLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:stretchColumns="1"
android:backgroundTint="#ff81d4fa">
<LinearLayout
android:orientation="vertical"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingLeft="10dip">
</LinearLayout>
<TextView
android:id="@+id/Text1"
android:text="Demo Item Name"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="@color/blue"
android:textSize="20dip" />
<TextView
android:id="@+id/Text2"
android:text="Demo Price"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textSize="14dip"
android:textColor="@color/blue" />
</TableLayout>
</ScrollView>
</LinearLayout>
についてはMyMenuRestaurent.axml
<LinearLayout>
<ListView>
</ListView>
</LinearLayout>
コード用 1)MyMenuRestaurent.axml 2)ImageAndSubTitle.axml
コードIは、リストビュークリッカブルを持っています。 1つのアイテムをクリックすると、個々のアイテムの詳細が開きます。私はスクロールビュー(クリック)を追加する場合は動作していません。スクロール・ビュー・ブロックが要素をクリックするためです。私はスクロールビューと一緒にアイテムをクリックしたい。
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="horizontal"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:background="@color/lightgray"
android:descendantFocusability="blocksDescendants">
それが役に立てば幸い:
を、あなたの問題を解決しましたか? –
unfortunatley no! – DevKriya
それでは、何が問題なのですか?あなたがこの問題を解決するのを手助けできるように、それを詳しく教えてください。 –