Fixing bugs

This commit is contained in:
h4h13 2019-09-28 23:22:49 +05:30
commit 2be114da11
110 changed files with 1049 additions and 1070 deletions

View file

@ -1,160 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout 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_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<LinearLayout
android:id="@+id/userInfoContainer"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:gravity="center_vertical"
android:orientation="horizontal"
android:padding="24dp">
<code.name.monkey.retromusic.views.CircularImageView
android:id="@+id/userImage"
android:layout_width="42dp"
android:layout_height="42dp"
app:civ_border="false" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:paddingStart="16dp"
android:paddingEnd="0dp">
<com.google.android.material.textview.MaterialTextView
android:id="@+id/text"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:ellipsize="end"
android:text="@string/welcome"
android:textColor="?colorOnBackground" />
<com.google.android.material.textview.MaterialTextView
android:id="@+id/titleWelcome"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:padding="0dp"
android:textAppearance="@style/TextViewHeadline5"
android:textColor="?colorOnPrimary"
tools:text="@string/app_name" />
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<LinearLayout
android:id="@+id/history"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="0"
android:orientation="vertical"
android:paddingStart="12dp"
android:paddingEnd="12dp">
<code.name.monkey.retromusic.views.ColorIconsImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:padding="24dp"
app:iconBackgroundColor="@color/md_blue_A700"
app:srcCompat="@drawable/ic_access_time_white_24dp" />
<code.name.monkey.appthemehelper.common.views.ATESecondaryTextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:paddingTop="8dp"
android:text="@string/history" />
</LinearLayout>
<LinearLayout
android:id="@+id/lastAdded"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="0"
android:orientation="vertical"
android:paddingStart="12dp"
android:paddingEnd="12dp">
<code.name.monkey.retromusic.views.ColorIconsImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:padding="24dp"
app:iconBackgroundColor="@color/md_red_A700"
app:srcCompat="@drawable/ic_library_add_white_24dp" />
<code.name.monkey.appthemehelper.common.views.ATESecondaryTextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:paddingTop="8dp"
android:text="@string/last_added" />
</LinearLayout>
<LinearLayout
android:id="@+id/topPlayed"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="0"
android:orientation="vertical"
android:paddingStart="12dp"
android:paddingEnd="12dp">
<code.name.monkey.retromusic.views.ColorIconsImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:padding="24dp"
app:iconBackgroundColor="@color/md_deep_purple_A700"
app:srcCompat="@drawable/ic_trending_up_white_24dp" />
<code.name.monkey.appthemehelper.common.views.ATESecondaryTextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:paddingTop="8dp"
android:text="@string/my_top_tracks" />
</LinearLayout>
<LinearLayout
android:id="@+id/actionShuffle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="0"
android:orientation="vertical"
android:paddingStart="12dp"
android:paddingEnd="12dp">
<code.name.monkey.retromusic.views.ColorIconsImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:padding="24dp"
app:iconBackgroundColor="@color/md_green_A700"
app:srcCompat="@drawable/ic_shuffle_white_24dp" />
<code.name.monkey.appthemehelper.common.views.ATESecondaryTextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:paddingTop="8dp"
android:text="@string/shuffle" />
</LinearLayout>
</LinearLayout>
</LinearLayout>

View file

@ -11,7 +11,8 @@
android:id="@+id/artistImage"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:scaleType="centerCrop" />
android:scaleType="centerCrop"
tools:srcCompat="@tools:sample/backgrounds/scenic[15]" />
<com.google.android.material.appbar.AppBarLayout
@ -33,7 +34,7 @@
android:layout_width="320dp"
android:layout_height="wrap_content" />
<code.name.monkey.appthemehelper.common.views.ATEToolbar
<com.google.android.material.appbar.MaterialToolbar
android:id="@+id/toolbar"
style="@style/Toolbar"
app:layout_collapseMode="pin"
@ -86,7 +87,8 @@
android:id="@+id/image"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:scaleType="centerCrop" />
android:scaleType="centerCrop"
tools:srcCompat="@tools:sample/backgrounds/scenic[14]" />
</com.google.android.material.card.MaterialCardView>
</code.name.monkey.retromusic.views.WidthFitSquareLayout>
@ -98,15 +100,16 @@
android:paddingStart="16dp"
android:paddingEnd="16dp">
<code.name.monkey.appthemehelper.common.views.ATEPrimaryTextView
<com.google.android.material.textview.MaterialTextView
android:id="@+id/albumTitle"
style="@style/TextAppearance.MaterialComponents.Headline4"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:maxLines="2"
tools:ignore="MissingPrefix" />
android:textAppearance="@style/TextViewHeadline4"
tools:ignore="MissingPrefix"
tools:text="Album name" />
<code.name.monkey.appthemehelper.common.views.ATESecondaryTextView
<com.google.android.material.textview.MaterialTextView
android:id="@+id/albumText"
style="@style/TextAppearance.MaterialComponents.Headline6"
android:layout_width="match_parent"
@ -120,7 +123,7 @@
android:scrollHorizontally="true"
android:singleLine="true"
tools:ignore="MissingPrefix"
tools:text="Title" />
tools:text="Album details" />
</LinearLayout>
</LinearLayout>

View file

@ -1,113 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout 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_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingStart="8dp"
android:paddingEnd="8dp">
<com.google.android.material.button.MaterialButton
android:id="@+id/playAction"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginStart="4dp"
android:layout_marginEnd="4dp"
android:padding="10dp"
android:text="@string/action_play_all"
android:textAllCaps="false"
android:textAppearance="@style/TextViewNormal"
app:cornerRadius="6dp"
app:icon="@drawable/ic_play_arrow_white_24dp"
app:iconGravity="textStart"
app:layout_constraintEnd_toStartOf="@+id/shuffleAction"
app:layout_constraintHorizontal_bias="0.5"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
tools:backgroundTint="@color/md_grey_900" />
<com.google.android.material.button.MaterialButton
android:id="@+id/shuffleAction"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginStart="4dp"
android:layout_marginEnd="4dp"
android:padding="10dp"
android:text="@string/shuffle"
android:textAllCaps="false"
android:textAppearance="@style/TextViewNormal"
app:cornerRadius="6dp"
app:icon="@drawable/ic_shuffle_white_24dp"
app:iconGravity="textStart"
app:layout_constraintBottom_toBottomOf="@+id/playAction"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.5"
app:layout_constraintStart_toEndOf="@+id/playAction"
app:layout_constraintTop_toTopOf="@+id/playAction"
tools:backgroundTint="@color/md_grey_900" />
</androidx.constraintlayout.widget.ConstraintLayout>
<code.name.monkey.appthemehelper.common.views.ATEPrimaryTextView
android:id="@+id/biographyTitle"
style="@style/SubTitleTextAppearance"
android:text="@string/biography"
android:visibility="gone"
tools:visibility="visible" />
<code.name.monkey.appthemehelper.common.views.ATEPrimaryTextView
android:id="@+id/biographyText"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:ellipsize="end"
android:maxLines="4"
android:padding="16dp"
android:textAppearance="@style/TextAppearance.AppCompat.Body1"
android:visibility="gone"
tools:visibility="visible" />
<code.name.monkey.appthemehelper.common.views.ATEPrimaryTextView
android:id="@+id/albumTitle"
style="@style/TextAppearance.MaterialComponents.Subtitle2"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingStart="24dp"
android:paddingTop="12dp"
android:paddingEnd="24dp"
android:paddingBottom="12dp"
android:text="@string/albums"
android:textColor="?android:attr/textColorPrimary"
android:textStyle="bold" />
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/albumRecyclerView"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:nestedScrollingEnabled="false" />
<code.name.monkey.appthemehelper.common.views.ATEPrimaryTextView
android:id="@+id/songTitle"
style="@style/TextAppearance.MaterialComponents.Subtitle2"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingStart="24dp"
android:paddingTop="12dp"
android:paddingEnd="24dp"
android:paddingBottom="12dp"
android:text="@string/songs"
android:textColor="?android:attr/textColorPrimary"
android:textStyle="bold"
tools:ignore="MissingPrefix" />
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recyclerView"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:nestedScrollingEnabled="false" />
</LinearLayout>

View file

@ -11,7 +11,8 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:scaleType="centerCrop"
android:transitionName="@string/transition_artist_image" />
android:transitionName="@string/transition_artist_image"
tools:srcCompat="@tools:sample/backgrounds/scenic[16]" />
<com.google.android.material.appbar.AppBarLayout
android:layout_width="match_parent"
@ -60,38 +61,29 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:elevation="@dimen/card_elevation"
android:orientation="vertical"
tools:background="@color/md_red_500">
android:orientation="vertical">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:padding="12dp">
android:padding="24dp">
<code.name.monkey.appthemehelper.common.views.ATEPrimaryTextView
<com.google.android.material.textview.MaterialTextView
android:id="@+id/artistTitle"
style="@style/TextAppearance.MaterialComponents.Headline4"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:maxLines="2"
android:textAppearance="@style/TextViewHeadline4"
tools:ignore="MissingPrefix"
tools:text="Title" />
<code.name.monkey.appthemehelper.common.views.ATESecondaryTextView
<com.google.android.material.textview.MaterialTextView
android:id="@+id/text"
style="@style/TextAppearance.MaterialComponents.Headline6"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:ellipsize="marquee"
android:focusable="true"
android:focusableInTouchMode="true"
android:freezesText="true"
android:marqueeRepeatLimit="marquee_forever"
android:scrollHorizontally="true"
android:singleLine="true"
android:textAppearance="@style/TextViewHeadline6"
tools:ignore="MissingPrefix"
tools:text="Title" />

View file

@ -75,16 +75,23 @@
android:id="@+id/toolbarContainer"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="64dp"
android:layout_marginEnd="64dp"
android:layout_marginStart="@dimen/toolbar_margin_horizontal"
android:layout_marginTop="@dimen/toolbar_margin_vertical"
android:layout_marginEnd="@dimen/toolbar_margin_horizontal"
android:layout_marginBottom="@dimen/toolbar_margin_vertical"
app:cardCornerRadius="8dp"
app:cardElevation="6dp"
app:cardUseCompatPadding="true"
app:layout_scrollFlags="scroll|enterAlways">
<code.name.monkey.appthemehelper.common.views.ATEToolbar
<com.google.android.material.appbar.MaterialToolbar
android:id="@+id/toolbar"
style="@style/Toolbar"
android:layout_width="match_parent"
android:layout_height="@dimen/toolbar_height"
android:background="?colorSurface"
app:contentInsetStart="0dp"
app:contentInsetStartWithNavigation="0dp"
app:popupTheme="?toolbarPopupTheme"
app:title="@string/search_hint"
app:titleMarginStart="0dp"
app:titleTextAppearance="@style/ToolbarTextAppearanceSearch"

View file

@ -1,5 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
<?xml version="1.0" encoding="utf-8"?><!--
~ Copyright (c) 2019 Hemanth Savarala.
~
~ Licensed under the GNU General Public License v3
@ -46,8 +45,10 @@
android:id="@+id/toolbarContainer"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="64dp"
android:layout_marginEnd="64dp"
android:layout_marginStart="@dimen/toolbar_margin_horizontal"
android:layout_marginTop="@dimen/toolbar_margin_vertical"
android:layout_marginEnd="@dimen/toolbar_margin_horizontal"
android:layout_marginBottom="@dimen/toolbar_margin_vertical"
app:cardCornerRadius="8dp"
app:cardElevation="0dp"
app:cardUseCompatPadding="true"
@ -55,9 +56,14 @@
app:strokeColor="?dividerColor"
app:strokeWidth="1dp">
<code.name.monkey.appthemehelper.common.views.ATEToolbar
<com.google.android.material.appbar.MaterialToolbar
android:id="@+id/toolbar"
style="@style/Toolbar"
android:layout_width="match_parent"
android:layout_height="@dimen/toolbar_height"
android:background="?colorSurface"
app:contentInsetStart="0dp"
app:contentInsetStartWithNavigation="0dp"
app:popupTheme="?toolbarPopupTheme"
app:title="@string/search_hint"
app:titleMarginStart="0dp"
app:titleTextAppearance="@style/ToolbarTextAppearanceSearch"

View file

@ -4,7 +4,7 @@
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="48dp"
android:background="@android:color/transparent"
android:background="?colorSurface"
android:clickable="true"
android:focusable="false"
android:transitionName="@string/transition_mini_player"

View file

@ -1,6 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout 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_width="156dp"
android:layout_height="wrap_content"
android:layout_margin="8dp"
@ -17,7 +18,8 @@
app:civ_border="false" />
</code.name.monkey.retromusic.views.WidthFitSquareLayout>
<code.name.monkey.appthemehelper.common.views.ATEPrimaryTextView
<com.google.android.material.textview.MaterialTextView
android:id="@+id/title"
android:layout_width="match_parent"
android:layout_height="wrap_content"
@ -25,5 +27,6 @@
android:gravity="center"
android:maxLines="1"
android:paddingTop="12dp"
android:textAppearance="@style/TextViewNormal" />
android:textAppearance="@style/TextViewNormal"
tools:text="Name" />
</LinearLayout>

View file

@ -1,6 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout 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_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical">
@ -10,7 +11,7 @@
android:layout_height="match_parent"
android:orientation="vertical">
<androidx.cardview.widget.CardView
<com.google.android.material.card.MaterialCardView
android:id="@+id/image_container_card"
android:layout_width="match_parent"
android:layout_height="match_parent"
@ -23,17 +24,19 @@
android:id="@+id/image"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:scaleType="centerCrop" />
</androidx.cardview.widget.CardView>
android:scaleType="centerCrop"
tools:srcCompat="@tools:sample/backgrounds/scenic[17]" />
</com.google.android.material.card.MaterialCardView>
</code.name.monkey.retromusic.views.WidthFitSquareLayout>
<code.name.monkey.appthemehelper.common.views.ATEPrimaryTextView
<com.google.android.material.textview.MaterialTextView
android:id="@+id/title"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:ellipsize="end"
android:maxLines="1"
android:padding="10dp"
android:textAppearance="@style/TextViewNormal" />
android:textAppearance="@style/TextViewNormal"
tools:text="Song title" />
</LinearLayout>