In the camera app layout it has:
camera.xml:
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/app_root"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<include layout="@layout/preview_frame"/>
<include layout="@layout/camera_control"/>
</LinearLayout>
and preview_frame.xml is
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/frame_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_weight="1">
.....
</RelativeLayout>
and camera_control.xml is:
<ControlPanelLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/control_panel"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:minHeight="76dp"
android:background="@drawable/bg_camera_pattern">
.....
</ControlPanelLayout>
My question is what is the 'layout_weight="1" ' in preview_frame.xml for? I have read about layout_weight but most of the time it used with layout_width="0px" And in camera_control, it does not have any layout_weight specified.
But in this case, it is not.
Thank you.