mirror of
https://github.com/playmusicexporter/playmusicexporter
synced 2024-05-17 05:16:42 +00:00
Started creation of the card based layout. See #18.
This commit is contained in:
parent
fb620132e8
commit
f4e32793e6
|
@ -62,5 +62,8 @@ dependencies {
|
||||||
compile 'com.android.support:support-v4:25.2.0'
|
compile 'com.android.support:support-v4:25.2.0'
|
||||||
compile 'com.android.support:design:25.2.0'
|
compile 'com.android.support:design:25.2.0'
|
||||||
compile 'com.android.support:support-vector-drawable:25.2.0'
|
compile 'com.android.support:support-vector-drawable:25.2.0'
|
||||||
|
compile 'com.android.support:cardview-v7:25.2.0'
|
||||||
|
compile 'com.android.support:recyclerview-v7:25.2.0'
|
||||||
|
compile 'com.android.support.constraint:constraint-layout:1.0.1'
|
||||||
compile 'com.github.paolorotolo:appintro:4.1.0'
|
compile 'com.github.paolorotolo:appintro:4.1.0'
|
||||||
}
|
}
|
||||||
|
|
BIN
playmusicexporter/src/main/res/drawable/beatles.webp
Normal file
BIN
playmusicexporter/src/main/res/drawable/beatles.webp
Normal file
Binary file not shown.
After Width: | Height: | Size: 18 KiB |
|
@ -0,0 +1,9 @@
|
||||||
|
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:width="24dp"
|
||||||
|
android:height="24dp"
|
||||||
|
android:viewportWidth="24.0"
|
||||||
|
android:viewportHeight="24.0">
|
||||||
|
<path
|
||||||
|
android:fillColor="#FF000000"
|
||||||
|
android:pathData="M7.41,7.84L12,12.42l4.59,-4.58L18,9.25l-6,6 -6,-6z"/>
|
||||||
|
</vector>
|
|
@ -0,0 +1,101 @@
|
||||||
|
<?xml version="1.0" encoding="utf-8"?><!--
|
||||||
|
~ Copyright (c) 2017 Jan Christian Grünhage
|
||||||
|
~
|
||||||
|
~ Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
|
~ of this software and associated documentation files (the "Software"), to deal
|
||||||
|
~ in the Software without restriction, including without limitation the rights
|
||||||
|
~ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||||
|
~ copies of the Software, and to permit persons to whom the Software is
|
||||||
|
~ furnished to do so, subject to the following conditions:
|
||||||
|
~
|
||||||
|
~ The above copyright notice and this permission notice shall be included in
|
||||||
|
~ all copies or substantial portions of the Software.
|
||||||
|
~
|
||||||
|
~ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
~ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
~ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
~ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
~ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||||
|
~ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||||
|
~ THE SOFTWARE.
|
||||||
|
-->
|
||||||
|
|
||||||
|
<android.support.v7.widget.CardView xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:card_view="http://schemas.android.com/apk/res-auto"
|
||||||
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
|
android:id="@+id/card_view"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_gravity="center"
|
||||||
|
android:layout_margin="20dp"
|
||||||
|
card_view:cardCornerRadius="4dp">
|
||||||
|
|
||||||
|
<android.support.constraint.ConstraintLayout
|
||||||
|
android:orientation="vertical"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/image_music_track_artwork"
|
||||||
|
android:layout_width="84dp"
|
||||||
|
android:layout_height="84dp"
|
||||||
|
android:layout_margin="20dp"
|
||||||
|
android:scaleType="centerCrop"
|
||||||
|
android:src="@drawable/beatles"
|
||||||
|
android:layout_marginLeft="8dp"
|
||||||
|
card_view:layout_constraintLeft_toLeftOf="parent"
|
||||||
|
card_view:layout_constraintTop_toTopOf="parent"
|
||||||
|
android:layout_marginTop="8dp"
|
||||||
|
android:layout_marginStart="8dp"
|
||||||
|
card_view:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
android:layout_marginBottom="8dp" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:paddingBottom="8dp"
|
||||||
|
android:id="@+id/text_music_track_list_title"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:maxLines="2"
|
||||||
|
android:text="Yellow Submarine"
|
||||||
|
android:textAppearance="?android:attr/textAppearanceLarge"
|
||||||
|
android:textColor="@color/text_music_title"
|
||||||
|
android:textSize="16sp"
|
||||||
|
tools:layout_constraintTop_creator="1"
|
||||||
|
android:layout_marginTop="8dp"
|
||||||
|
tools:layout_constraintLeft_creator="1"
|
||||||
|
android:layout_marginLeft="8dp"
|
||||||
|
card_view:layout_constraintTop_toTopOf="@+id/image_music_track_artwork"
|
||||||
|
card_view:layout_constraintLeft_toRightOf="@+id/image_music_track_artwork"
|
||||||
|
android:layout_marginStart="8dp" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/text_music_track_list_description"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:maxLines="2"
|
||||||
|
android:text="The Beatles"
|
||||||
|
android:textAppearance="?android:attr/textAppearanceSmall"
|
||||||
|
android:textColor="@color/text_music_description"
|
||||||
|
tools:layout_constraintTop_creator="1"
|
||||||
|
card_view:layout_constraintTop_toBottomOf="@+id/text_music_track_list_title"
|
||||||
|
tools:layout_constraintLeft_creator="1"
|
||||||
|
card_view:layout_constraintLeft_toLeftOf="@+id/text_music_track_list_title" />
|
||||||
|
|
||||||
|
|
||||||
|
<ImageButton
|
||||||
|
android:id="@+id/imageButton"
|
||||||
|
style="@style/Widget.AppCompat.ImageButton"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginBottom="8dp"
|
||||||
|
android:background="@null"
|
||||||
|
android:elevation="0dp"
|
||||||
|
card_view:layout_constraintBottom_toBottomOf="@+id/image_music_track_artwork"
|
||||||
|
card_view:layout_constraintTop_toBottomOf="@+id/image_music_track_artwork"
|
||||||
|
card_view:srcCompat="@drawable/ic_keyboard_arrow_down_black_24dp"
|
||||||
|
android:layout_marginRight="8dp"
|
||||||
|
card_view:layout_constraintRight_toRightOf="parent"
|
||||||
|
android:layout_marginEnd="8dp" />
|
||||||
|
|
||||||
|
</android.support.constraint.ConstraintLayout>
|
||||||
|
</android.support.v7.widget.CardView>
|
Loading…
Reference in a new issue