私は次のレイアウトを持っています:
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<android.support.v4.widget.NestedScrollView
android:id="@+id/nestedscrollview"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<LinearLayout
android:id="@+id/inner_container"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<NESTED VIEWS>
</LinearLayout>
</android.support.v4.widget.NestedScrollView>
<LinearLayout
android:id="@+id/outer_container"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<OUTER VIEWS>
</LinearLayout>
</LinearLayout>
</ScrollView>
私の質問は、ScrollView を最初にスクロールさせたいということです。ScrollView が少しでも移動した場合は、NestedScrollView がタッチを消費する可能性があります。現在、NestedScrollView はタッチ イベントを取得し、スクロールを消費してから、ScrollView はタッチを受け取ります。onInterceptTouchEvent を使用して実験しましたが、役に立ちませんでした。ポインタはありますか?
これは正しいアプローチですか、それとも他のビューの組み合わせを使用しますか? (コーディネーター配置かな?)