diff options
Diffstat (limited to 'androidApp/src/main/res/layout')
-rw-r--r-- | androidApp/src/main/res/layout/unit_item.xml | 35 |
1 files changed, 27 insertions, 8 deletions
diff --git a/androidApp/src/main/res/layout/unit_item.xml b/androidApp/src/main/res/layout/unit_item.xml index e827940..833e56b 100644 --- a/androidApp/src/main/res/layout/unit_item.xml +++ b/androidApp/src/main/res/layout/unit_item.xml @@ -57,18 +57,33 @@ android:clickable="true" android:focusable="true"> - <LinearLayout + <androidx.constraintlayout.widget.ConstraintLayout android:id="@+id/mainContent" android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="vertical"> + <ImageView + android:id="@+id/unitIcon" + android:layout_width="0dp" + android:layout_height="wrap_content" + android:padding="@dimen/card_icon_padding" + android:paddingStart="0dp" + android:src="@drawable/map_default" + app:layout_constraintStart_toStartOf="parent" + app:layout_constraintTop_toTopOf="parent" + app:layout_constraintBottom_toBottomOf="parent" + tools:ignore="ContentDescription,RtlSymmetry" /> + <LinearLayout android:id="@+id/titleLayout" - android:layout_width="match_parent" + android:layout_width="0dp" android:layout_height="wrap_content" android:gravity="center_vertical" - android:orientation="horizontal"> + android:orientation="horizontal" + app:layout_constraintStart_toEndOf="@id/unitIcon" + app:layout_constraintEnd_toEndOf="parent" + app:layout_constraintTop_toTopOf="parent"> <ImageView android:id="@+id/statusIcon" @@ -83,26 +98,30 @@ android:id="@+id/engineStopIcon" android:layout_width="wrap_content" android:layout_height="wrap_content" - android:visibility="gone" android:layout_marginEnd="5dp" android:src="@drawable/device_unlocked" + android:visibility="gone" tools:ignore="ContentDescription" /> <TextView android:id="@+id/unitName" + style="@style/TextAppearance.AppCompat.Body2" android:layout_width="match_parent" android:layout_height="wrap_content" - style="@style/TextAppearance.AppCompat.Body2" tools:text="1AAUTO" /> </LinearLayout> <GridLayout android:id="@+id/gridLayout" - android:layout_width="match_parent" - android:layout_height="wrap_content" /> + android:layout_width="0dp" + android:layout_height="wrap_content" + app:layout_constraintEnd_toEndOf="parent" + app:layout_constraintStart_toEndOf="@id/unitIcon" + app:layout_constraintTop_toBottomOf="@id/titleLayout" + app:layout_constraintBottom_toBottomOf="parent"/> - </LinearLayout> + </androidx.constraintlayout.widget.ConstraintLayout> </com.google.android.material.card.MaterialCardView> |