Ваш LinearLayout
, содержащий кнопки, имеет layout_height="fill_parent"
. Вам необходимо установить значение wrap_content
, а также указать orientation="vertical"
в родительском элементе LinearLayout
. Вам также необходимо указать layout_weight
для представления, которое вы хотите растянуть для заполнения.
Поскольку linearLayout01
LinearLayout
имеет layout_height
, установленный на fill_parent
, Android заставит его выполнить сброс экрана. Содержимое ниже, которое вообще не будет видно, потому что оно не на экране.
<LinearLayout
android:id="@+id/linearLayout01"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical"
xmlns:android="http://schemas.android.com/apk/res/android">
<LinearLayout
android:id="@+id/linearLayout02"
android:layout_width="fill_parent"
android:layout_height="wrap_content">
<Button android:id="@+id/button01" android:layout_height="wrap_content" android:text="Button 1" android:layout_width="0dip" android:layout_weight="1"></Button>
<Button android:id="@+id/button02" android:layout_height="wrap_content" android:text="Button 2" android:layout_width="0dip" android:layout_weight="1"></Button>
</LinearLayout>
<RelativeLayout
android:id="@+id/relativeLayout01"
android:layout_width="fill_parent"
android:layout_height="0dp"
android:layout_weight="1">
<ViewFlipper
android:id="@+id/flipper01"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
>
<TextView
android:id="@+id/textview01"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Text"
/>
<TextView
android:id="@+id/textview02"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Text2"
/>
</ViewFlipper>
</RelativeLayout>
</LinearLayout>