aboutsummaryrefslogtreecommitdiff
path: root/androidApp/src/main/res/layout/unit_details_commands.xml
diff options
context:
space:
mode:
authorIván Ávalos <avalos@disroot.org>2022-01-14 03:02:41 -0600
committerIván Ávalos <avalos@disroot.org>2022-01-14 03:02:41 -0600
commit81a0b6689e94b8a10ebf68dccbb94a1f11507487 (patch)
tree211a24d64df149a1bc1587b19f2d65dedba012b5 /androidApp/src/main/res/layout/unit_details_commands.xml
parent3692d0de20a85ef7e22a31aa9f842078fb774bbe (diff)
downloadetbsa-trackermap-mobile-81a0b6689e94b8a10ebf68dccbb94a1f11507487.tar.gz
etbsa-trackermap-mobile-81a0b6689e94b8a10ebf68dccbb94a1f11507487.tar.bz2
etbsa-trackermap-mobile-81a0b6689e94b8a10ebf68dccbb94a1f11507487.zip
Pass device name to details activity and redesigned commands fragment
Diffstat (limited to 'androidApp/src/main/res/layout/unit_details_commands.xml')
-rw-r--r--androidApp/src/main/res/layout/unit_details_commands.xml60
1 files changed, 44 insertions, 16 deletions
diff --git a/androidApp/src/main/res/layout/unit_details_commands.xml b/androidApp/src/main/res/layout/unit_details_commands.xml
index 6e1d7b2..6b554cc 100644
--- a/androidApp/src/main/res/layout/unit_details_commands.xml
+++ b/androidApp/src/main/res/layout/unit_details_commands.xml
@@ -2,6 +2,7 @@
<androidx.constraintlayout.widget.ConstraintLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
+ xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent">
@@ -12,29 +13,56 @@
app:cardCornerRadius="@dimen/card_border_radius"
app:cardElevation="@dimen/card_elevation"
app:cardUseCompatPadding="true"
- app:layout_constraintBottom_toTopOf="@id/sendCommandButton"
+ app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent">
- <ListView
- android:id="@+id/commandsList"
+ <androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
- android:choiceMode="singleChoice"
- android:listSelector="@color/darkBackground" />
+ android:orientation="vertical">
- </com.google.android.material.card.MaterialCardView>
+ <TextView
+ android:id="@+id/nameDetail"
+ style="@style/TextAppearance.AppCompat.Headline"
+ android:layout_width="0dp"
+ android:layout_height="wrap_content"
+ android:textColor="@color/colorPrimaryDark"
+ android:layout_margin="@dimen/card_padding"
+ android:layout_marginBottom="@dimen/margin"
+ app:layout_constraintTop_toTopOf="parent"
+ app:layout_constraintStart_toStartOf="parent"
+ app:layout_constraintEnd_toEndOf="parent"
+ app:layout_constraintBottom_toTopOf="@id/commandsList"
+ tools:text="1AAUTO" />
- <com.google.android.material.button.MaterialButton
- android:id="@+id/sendCommandButton"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:layout_marginBottom="@dimen/margin"
- android:text="@string/send_command"
- app:layout_constraintBottom_toBottomOf="parent"
- app:layout_constraintEnd_toEndOf="parent"
- app:layout_constraintStart_toStartOf="parent"
- app:layout_constraintTop_toBottomOf="@id/commandsCard" />
+ <ListView
+ android:id="@+id/commandsList"
+ android:layout_width="0dp"
+ android:layout_height="0dp"
+ android:choiceMode="singleChoice"
+ android:listSelector="@color/darkBackground"
+ app:layout_constraintTop_toBottomOf="@id/nameDetail"
+ app:layout_constraintStart_toStartOf="parent"
+ app:layout_constraintEnd_toEndOf="parent"
+ app:layout_constraintBottom_toTopOf="@id/sendCommandButton" />
+
+ <com.google.android.material.button.MaterialButton
+ android:id="@+id/sendCommandButton"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_margin="@dimen/margin"
+ android:text="@string/send_command"
+ android:enabled="false"
+ app:layout_constraintTop_toBottomOf="@id/commandsList"
+ app:layout_constraintBottom_toBottomOf="parent"
+ app:layout_constraintStart_toStartOf="parent"
+ app:layout_constraintEnd_toEndOf="parent"
+ />
+
+ </androidx.constraintlayout.widget.ConstraintLayout>
+
+ </com.google.android.material.card.MaterialCardView>
</androidx.constraintlayout.widget.ConstraintLayout> \ No newline at end of file