114 lines
5.1 KiB
XML
114 lines
5.1 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<!--
|
|
Copyright 2018, The Android Open Source Project
|
|
|
|
Licensed under the Apache License, Version 2.0 (the "License");
|
|
you may not use this file except in compliance with the License.
|
|
You may obtain a copy of the License at
|
|
|
|
http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
Unless required by applicable law or agreed to in writing, software
|
|
distributed under the License is distributed on an "AS IS" BASIS,
|
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
See the License for the specific language governing permissions and
|
|
limitations under the License.
|
|
-->
|
|
<androidx.cardview.widget.CardView
|
|
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_height="match_parent"
|
|
android:layout_width="match_parent"
|
|
app:cardElevation="0dp"
|
|
app:cardCornerRadius="6dp">
|
|
|
|
<View
|
|
android:id="@+id/playback_scrim"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="match_parent"
|
|
android:background="@color/album_art_scrim"
|
|
android:alpha="@dimen/album_art_scrim_alpha"/>
|
|
|
|
<androidx.constraintlayout.widget.ConstraintLayout
|
|
xmlns:android="http://schemas.android.com/apk/res/android"
|
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
|
android:id="@+id/playback_container"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="match_parent">
|
|
|
|
<TextView
|
|
android:id="@+id/app_name"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginTop="@dimen/playback_fragment_text_margin_top"
|
|
android:layout_marginLeft="@dimen/playback_fragment_text_margin_x"
|
|
android:layout_marginRight="@dimen/playback_fragment_text_margin_x"
|
|
android:textAppearance="?android:attr/textAppearanceMedium"
|
|
android:ellipsize="end"
|
|
android:maxLines="1"
|
|
android:includeFontPadding="false"
|
|
app:layout_constraintLeft_toLeftOf="parent"
|
|
app:layout_constraintTop_toTopOf="parent"/>
|
|
|
|
<ImageView
|
|
android:id="@+id/app_icon"
|
|
android:layout_width="@dimen/playback_app_icon_size"
|
|
android:layout_height="@dimen/playback_app_icon_size"
|
|
android:layout_marginTop="@dimen/playback_fragment_icon_margin_top"
|
|
android:layout_marginLeft="@dimen/playback_fragment_icon_margin_x"
|
|
app:layout_constraintStart_toEndOf="@+id/app_name"
|
|
app:layout_constraintTop_toTopOf="parent"/>
|
|
|
|
<androidx.constraintlayout.widget.Guideline
|
|
android:id="@+id/margin_start"
|
|
android:layout_width="0dp"
|
|
android:layout_height="0dp"
|
|
android:orientation="vertical"
|
|
app:layout_constraintGuide_begin="@dimen/fragment_playback_guide_margin_x"/>
|
|
|
|
<androidx.constraintlayout.widget.Guideline
|
|
android:id="@+id/margin_end"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:orientation="vertical"
|
|
app:layout_constraintGuide_end="@dimen/fragment_playback_guide_margin_x"/>
|
|
|
|
<androidx.constraintlayout.widget.Guideline
|
|
android:id="@+id/margin_top"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:orientation="horizontal"
|
|
app:layout_constraintGuide_begin="@dimen/fragment_playback_guide_margin_top"/>
|
|
|
|
<ImageView
|
|
android:id="@+id/album_art"
|
|
android:layout_width="@dimen/playback_album_art_size_normal"
|
|
android:layout_height="@dimen/playback_album_art_size_normal"
|
|
android:layout_marginStart="@dimen/fragment_metadata_art_margin_start"
|
|
android:layout_marginEnd="@dimen/fragment_metadata_art_margin_end"
|
|
android:contentDescription="@string/album_art"
|
|
android:background="@color/album_art_background"
|
|
android:scaleType="centerCrop"
|
|
android:transitionName="@string/album_art"
|
|
app:layout_constraintTop_toTopOf="@+id/app_name"
|
|
app:layout_constraintBottom_toBottomOf="parent"
|
|
app:layout_constraintStart_toStartOf="@+id/margin_start"
|
|
tools:src="@drawable/ic_person"/>
|
|
|
|
<include
|
|
android:id="@+id/metadata_subcontainer"
|
|
layout="@layout/metadata_normal"
|
|
android:layout_width="0dp"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginStart="@dimen/fragment_metadata_metadata_margin_start"
|
|
android:layout_marginEnd="@dimen/fragment_metadata_metadata_margin_end"
|
|
app:layout_constraintBottom_toBottomOf="@+id/album_art"
|
|
app:layout_constraintEnd_toEndOf="@+id/margin_end"
|
|
app:layout_constraintStart_toEndOf="@+id/album_art"
|
|
app:layout_constraintTop_toTopOf="@+id/album_art"/>
|
|
|
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
|
|
</androidx.cardview.widget.CardView>
|