Files
examples/android-example/app/src/main/res/layout/fragment_control.xml

305 lines
14 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout
xmlns:tools="http://schemas.android.com/tools" android:id="@+id/sv_control"
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<LinearLayout
android:id="@+id/ll_control_panel"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:padding="8dp"
android:orientation="horizontal">
<ImageButton
android:id="@+id/iv_power"
android:layout_width="match_parent"
android:layout_height="64dp"
android:src="@mipmap/button_power"
android:paddingTop="16dp"
android:paddingBottom="16dp"
android:contentDescription="@string/button_power"
android:stateListAnimator="@animator/button_elevation_anim"
android:scaleType="fitCenter"
style="?android:buttonBarButtonStyle"/>
</LinearLayout>
<View
android:layout_width="match_parent"
android:layout_height="1dp"
android:layout_margin="4dp"
android:background="#7F7F7F" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="8dp"
android:orientation="horizontal">
<ImageButton
android:id="@+id/iv_back"
android:layout_width="match_parent"
android:layout_height="64dp"
android:src="@mipmap/button_back"
android:paddingTop="16dp"
android:paddingBottom="16dp"
android:layout_weight="1"
android:scaleType="fitCenter"
android:contentDescription="@string/button_back"
android:stateListAnimator="@animator/button_elevation_anim"
style="?android:buttonBarButtonStyle"/>
<ImageButton
android:id="@+id/iv_home"
android:layout_width="match_parent"
android:layout_height="64dp"
android:src="@mipmap/button_home"
android:paddingTop="16dp"
android:paddingBottom="16dp"
android:layout_weight="1"
android:scaleType="fitCenter"
android:contentDescription="@string/button_home"
android:stateListAnimator="@animator/button_elevation_anim"
style="?android:buttonBarButtonStyle"/>
<ImageButton
android:id="@+id/iv_menu"
android:layout_width="match_parent"
android:layout_height="64dp"
android:src="@mipmap/button_menu"
android:paddingTop="16dp"
android:paddingBottom="16dp"
android:layout_weight="1"
android:scaleType="fitCenter"
android:contentDescription="@string/button_menu"
android:stateListAnimator="@animator/button_elevation_anim"
style="?android:buttonBarButtonStyle"/>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="8dp"
android:orientation="horizontal">
<TextView
android:id="@+id/tv_empty_top_left"
android:layout_width="match_parent"
android:layout_height="64dp"
android:layout_weight="1"/>
<ImageButton
android:id="@+id/iv_up"
android:layout_width="match_parent"
android:layout_height="64dp"
android:src="@mipmap/button_up"
android:paddingTop="16dp"
android:paddingBottom="16dp"
android:layout_weight="1"
android:scaleType="fitCenter"
android:contentDescription="@string/button_up"
android:stateListAnimator="@animator/button_elevation_anim"
style="?android:buttonBarButtonStyle"/>
<TextView
android:id="@+id/tv_empty_top_right"
android:layout_width="match_parent"
android:layout_height="64dp"
android:layout_weight="1"/>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="8dp"
android:orientation="horizontal">
<ImageButton
android:id="@+id/iv_left"
android:layout_width="match_parent"
android:layout_height="64dp"
android:src="@mipmap/button_left"
android:paddingTop="16dp"
android:paddingBottom="16dp"
android:layout_weight="1"
android:scaleType="fitCenter"
android:contentDescription="@string/button_left"
android:stateListAnimator="@animator/button_elevation_anim"
style="?android:buttonBarButtonStyle"/>
<ImageButton
android:id="@+id/iv_ok"
android:layout_width="match_parent"
android:layout_height="64dp"
android:src="@mipmap/button_ok"
android:paddingTop="16dp"
android:paddingBottom="16dp"
android:layout_weight="1"
android:scaleType="fitCenter"
android:contentDescription="@string/button_ok"
android:stateListAnimator="@animator/button_elevation_anim"
style="?android:buttonBarButtonStyle"/>
<ImageButton
android:id="@+id/iv_right"
android:layout_width="match_parent"
android:layout_height="64dp"
android:src="@mipmap/button_right"
android:paddingTop="16dp"
android:paddingBottom="16dp"
android:layout_weight="1"
android:scaleType="fitCenter"
android:contentDescription="@string/button_right"
android:stateListAnimator="@animator/button_elevation_anim"
style="?android:buttonBarButtonStyle"/>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="8dp"
android:orientation="horizontal">
<TextView
android:id="@+id/tv_empty_bottom_left"
android:layout_width="match_parent"
android:layout_height="64dp"
android:layout_weight="1"/>
<ImageButton
android:id="@+id/iv_down"
android:layout_width="match_parent"
android:layout_height="64dp"
android:src="@mipmap/button_down"
android:paddingTop="16dp"
android:paddingBottom="16dp"
android:layout_weight="1"
android:scaleType="fitCenter"
android:contentDescription="@string/button_down"
android:stateListAnimator="@animator/button_elevation_anim"
style="?android:buttonBarButtonStyle"/>
<TextView
android:id="@+id/tv_empty_bottom_right"
android:layout_width="match_parent"
android:layout_height="64dp"
android:layout_weight="1"/>
</LinearLayout>
<View
android:layout_width="match_parent"
android:layout_height="1dp"
android:layout_margin="4dp"
android:background="#7F7F7F" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="8dp"
android:orientation="horizontal">
<ImageButton
android:id="@+id/iv_minus"
android:layout_width="match_parent"
android:layout_height="64dp"
android:src="@mipmap/button_minus"
android:paddingTop="16dp"
android:paddingBottom="16dp"
android:layout_weight="1"
android:scaleType="fitCenter"
android:contentDescription="@string/button_minus"
android:stateListAnimator="@animator/button_elevation_anim"
style="?android:buttonBarButtonStyle"/>
<TextView
android:id="@+id/tv_empty_center"
android:layout_width="match_parent"
android:layout_height="64dp"
android:layout_weight="1"/>
<ImageButton
android:id="@+id/iv_plus"
android:layout_width="match_parent"
android:layout_height="64dp"
android:src="@mipmap/button_plus"
android:paddingTop="16dp"
android:paddingBottom="16dp"
android:layout_weight="1"
android:scaleType="fitCenter"
android:contentDescription="@string/button_plus"
android:stateListAnimator="@animator/button_elevation_anim"
style="?android:buttonBarButtonStyle"/>
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:layout_alignParentBottom="true">
<View
android:layout_width="match_parent"
android:layout_height="1dp"
android:layout_margin="4dp"
android:background="#7F7F7F"/>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<CheckBox
android:id="@+id/cb_use_encoded"
android:layout_width="match_parent"
android:layout_height="60dp"
android:textSize="18sp"
android:layout_marginStart="20dp"
android:text="@string/decode_on_board"
android:layout_weight="1"
android:checked="false"/>
<TextView
android:id="@+id/tv_connection_status"
android:layout_width="match_parent"
android:layout_height="60dp"
android:gravity="center_vertical|end"
android:layout_marginEnd="20dp"
android:layout_weight="1"
android:textSize="18sp"
android:textColor="#FF7F7F"
android:text="@string/status_not_connected"/>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:layout_marginBottom="2dp"
android:layout_marginStart="20dp"
android:layout_marginEnd="20dp"
tools:ignore="UselessParent">
<TextView
android:layout_width="wrap_content"
android:layout_height="60dp"
android:gravity="center_vertical"
android:textSize="18sp"
android:paddingStart="8dp"
android:paddingEnd="8dp"
android:text="@string/emitter_ip">
</TextView>
<EditText
android:id="@+id/emitter_ip"
android:layout_width="0dp"
android:autofillHints=""
android:gravity="center_vertical"
android:textSize="18sp"
android:inputType="text"
android:text="@string/default_ip"
android:layout_height="60dp"
android:layout_weight="1">
</EditText>
<ImageButton
android:id="@+id/btn_connect_emitter"
android:layout_width="60dp"
android:layout_height="60dp"
android:padding="12dp"
android:src="@mipmap/button_link"
android:scaleType="fitCenter"
android:contentDescription="@string/connect"
android:stateListAnimator="@animator/button_elevation_anim"
style="?android:buttonBarButtonStyle"/>
</LinearLayout>
<View
android:layout_width="match_parent"
android:layout_height="1dp"
android:layout_margin="4dp"
android:background="#7F7F7F"/>
</LinearLayout>
</RelativeLayout>