1<?xml version="1.0" encoding="utf-8"?>
2<!--
3     Copyright 2018 The Android Open Source Project
4
5     Licensed under the Apache License, Version 2.0 (the "License");
6     you may not use this file except in compliance with the License.
7     You may obtain a copy of the License at
8
9        http://www.apache.org/licenses/LICENSE-2.0
10
11     Unless required by applicable law or agreed to in writing, software
12     distributed under the License is distributed on an "AS IS" BASIS,
13     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14     See the License for the specific language governing permissions and
15     limitations under the License.
16-->
17
18
19<androidx.constraintlayout.widget.ConstraintLayout
20    xmlns:android="http://schemas.android.com/apk/res/android"
21    xmlns:app="http://schemas.android.com/apk/res-auto"
22    xmlns:tools="http://schemas.android.com/tools"
23    android:layout_width="match_parent"
24    android:layout_height="match_parent">
25
26    <com.android.pump.widget.UriImageView
27        android:id="@+id/activity_genre_details_image"
28        android:layout_width="0dp"
29        android:layout_height="0dp"
30        android:scaleType="centerCrop"
31        app:layout_constraintTop_toTopOf="parent"
32        app:layout_constraintStart_toStartOf="parent"
33        app:layout_constraintEnd_toEndOf="parent"
34        app:layout_constraintDimensionRatio="1:1"
35        tools:src="@tools:sample/backgrounds/scenic"/>
36
37    <com.google.android.material.appbar.AppBarLayout
38        android:layout_width="match_parent"
39        android:layout_height="wrap_content"
40        android:background="@null"
41        app:layout_constraintTop_toTopOf="parent"
42        app:layout_constraintStart_toStartOf="parent"
43        app:layout_constraintEnd_toEndOf="parent"
44        app:elevation="0dp">
45
46        <androidx.appcompat.widget.Toolbar
47            android:id="@+id/activity_genre_details_toolbar"
48            android:layout_width="match_parent"
49            android:layout_height="?actionBarSize"/>
50
51    </com.google.android.material.appbar.AppBarLayout>
52
53    <com.android.pump.widget.UriImageView
54        android:id="@+id/activity_genre_details_play"
55        android:layout_width="48dp"
56        android:layout_height="48dp"
57        app:layout_constraintTop_toTopOf="@id/activity_genre_details_image"
58        app:layout_constraintBottom_toBottomOf="@id/activity_genre_details_image"
59        app:layout_constraintStart_toStartOf="@id/activity_genre_details_image"
60        app:layout_constraintEnd_toEndOf="@id/activity_genre_details_image"
61        app:srcCompat="@drawable/ic_play"
62        app:tint="?colorControlNormal"
63
64        android:clickable="true"
65        android:focusable="true"
66        android:foreground="?selectableItemBackground"/>
67
68    <android.view.View
69        android:layout_width="0dp"
70        android:layout_height="77dp"
71        android:background="@drawable/shadow"
72        app:layout_constraintBottom_toBottomOf="@id/activity_genre_details_image"
73        app:layout_constraintStart_toStartOf="@id/activity_genre_details_image"
74        app:layout_constraintEnd_toEndOf="@id/activity_genre_details_image"/>
75
76    <androidx.appcompat.widget.AppCompatTextView
77        android:id="@+id/activity_genre_details_name"
78        android:layout_width="0dp"
79        android:layout_height="wrap_content"
80        android:layout_marginStart="24dp"
81        android:layout_marginEnd="24dp"
82        android:textSize="18sp"
83        android:maxLines="3"
84        android:ellipsize="end"
85        app:layout_constraintTop_toBottomOf="@id/activity_genre_details_image"
86        app:layout_constraintStart_toStartOf="parent"
87        app:layout_constraintEnd_toEndOf="parent"
88        tools:text="Name"/>
89
90    <androidx.appcompat.widget.AppCompatTextView
91        android:id="@+id/activity_genre_details_count"
92        android:layout_width="0dp"
93        android:layout_height="wrap_content"
94        android:layout_marginTop="4dp"
95        android:textSize="12sp"
96        android:maxLines="1"
97        android:ellipsize="end"
98        app:layout_constraintTop_toBottomOf="@id/activity_genre_details_name"
99        app:layout_constraintStart_toStartOf="@id/activity_genre_details_name"
100        app:layout_constraintEnd_toEndOf="@id/activity_genre_details_name"
101        tools:text="22 audios"/>
102
103    <androidx.recyclerview.widget.RecyclerView
104        android:id="@+id/activity_genre_details_recycler_view"
105        android:layout_width="0dp"
106        android:layout_height="0dp"
107        android:layout_marginTop="4dp"
108        app:layout_constraintTop_toBottomOf="@id/activity_genre_details_count"
109        app:layout_constraintBottom_toBottomOf="parent"
110        app:layout_constraintStart_toStartOf="@id/activity_genre_details_count"
111        app:layout_constraintEnd_toEndOf="@id/activity_genre_details_count"
112        app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
113        tools:listitem="@layout/audio"/>
114
115</androidx.constraintlayout.widget.ConstraintLayout>
116