Move tags layout at the bottom, use multiple lines

pull/6463/head
Stypox 2021-06-13 21:56:06 +02:00
rodzic fa1d7ffac3
commit 40a2df847b
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 4BDF1B40A49FDD23
3 zmienionych plików z 24 dodań i 18 usunięć

Wyświetl plik

@ -154,8 +154,6 @@ public class DescriptionFragment extends BaseFragment {
addMetadataItem(inflater, layout, false,
R.string.metadata_category, streamInfo.getCategory());
addTagsMetadataItem(inflater, layout);
addMetadataItem(inflater, layout, false,
R.string.metadata_licence, streamInfo.getLicence());
@ -177,6 +175,8 @@ public class DescriptionFragment extends BaseFragment {
R.string.metadata_host, streamInfo.getHost());
addMetadataItem(inflater, layout, true,
R.string.metadata_thumbnail_url, streamInfo.getThumbnailUrl());
addTagsMetadataItem(inflater, layout);
}
private void addMetadataItem(final LayoutInflater inflater,

Wyświetl plik

@ -4,8 +4,7 @@
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="6dp"
android:paddingBottom="6dp">
android:paddingVertical="6dp">
<TextView
android:id="@+id/metadata_type_view"

Wyświetl plik

@ -1,24 +1,31 @@
<?xml version="1.0" encoding="utf-8"?>
<HorizontalScrollView xmlns:android="http://schemas.android.com/apk/res/android"
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_height="match_parent"
android:fadeScrollbars="false">
<TextView
android:id="@+id/metadata_type_view"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:gravity="center"
android:text="@string/metadata_tags"
android:textAllCaps="true"
android:textColor="?android:attr/textColorPrimary"
android:textStyle="bold"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<com.google.android.material.chip.ChipGroup
android:id="@+id/metadata_tags_chips"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
app:singleLine="true">
android:layout_marginTop="8dp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/metadata_type_view" />
<TextView
android:layout_width="96dp"
android:layout_height="40dp"
android:layout_marginEnd="8dp"
android:gravity="center_vertical|end"
android:text="@string/metadata_tags"
android:textAllCaps="true"
android:textColor="?android:attr/textColorPrimary"
android:textStyle="bold" />
</com.google.android.material.chip.ChipGroup>
</HorizontalScrollView>
</androidx.constraintlayout.widget.ConstraintLayout>