diff --git a/FAQ.md b/FAQ.md
index 2194d669..1a5407d9 100644
--- a/FAQ.md
+++ b/FAQ.md
@@ -8,8 +8,7 @@ You can opt-in for the beta build by clicking on this link: https://play.google.
- STEP 4: You have to copy or move the file into a location on the SD Card: whatever_sdcard/RetroMusic/lyrics/ and paste inside your ".lrc" file in there.
#### Q: Why isn't the artist's image downloading?
-STEP 1: Settings -> Images -> Auto-download artist images -> Always
-STEP 2: Open the artists tab and wait some time for the images to download.
+Last.fm has disabled the download of artist's images for the time being, whether functionality for this will be restored in future is uncertain.
#### Q: How do I change the theme?
Settings -> Look and feel -> Select your theme.
@@ -35,8 +34,5 @@ Clear the app's cache and data.
##### Q: My app is crashing, how do i fix this? (Sorry, settings have changed internally)
Reinstalling the app should fix this issue.
-##### Q: Artist images are not loading, why?
-The Last.fm service has a limited number of requests of download data it can handle (artist images). If that request limit is exceeded, it will not download for some time.
-
##### Q: Why has all the text gone white/dissapeared?
Change the theme to Black or Dark and change it back to what you had before.
diff --git a/README.md b/README.md
index a40cc4d1..632a710f 100644
--- a/README.md
+++ b/README.md
@@ -17,7 +17,6 @@ Retro Music is an open source, local music player for Android.
- Volume controls
- Blacklist
- Album artist support
-- Auto-download artist images from Last.fm
#### Download
diff --git a/app/build.gradle b/app/build.gradle
index 4ae66327..c0e2de1b 100644
--- a/app/build.gradle
+++ b/app/build.gradle
@@ -31,8 +31,8 @@ android {
vectorDrawables.useSupportLibrary = true
applicationId "code.name.monkey.retromusic"
- versionCode 336
- versionName '3.2.100'
+ versionCode 340
+ versionName '3.2.125'
multiDexEnabled true
@@ -132,9 +132,9 @@ dependencies {
implementation 'com.google.android.material:material:1.1.0-alpha07'
implementation 'com.google.android.material:material:1.1.0-alpha07'
- implementation 'com.squareup.retrofit2:retrofit:2.5.0'
- implementation 'com.squareup.retrofit2:converter-gson:2.5.0'
- implementation 'com.squareup.retrofit2:adapter-rxjava2:2.5.0'
+ implementation 'com.squareup.retrofit2:retrofit:2.6.0'
+ implementation 'com.squareup.retrofit2:converter-gson:2.6.0'
+ implementation 'com.squareup.retrofit2:adapter-rxjava2:2.6.0'
implementation 'com.afollestad.material-dialogs:core:3.0.0-alpha1'
implementation 'com.afollestad.material-dialogs:input:3.0.0-alpha1'
@@ -161,7 +161,6 @@ dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version"
implementation 'org.eclipse.mylyn.github:org.eclipse.egit.github.core:3.4.0.201406110918-r'
- implementation 'com.github.jetradarmobile:android-snowfall:1.2.0'
implementation 'com.github.takahirom.downloadable.calligraphy:downloadable-calligraphy:0.1.3'
implementation 'com.github.ksoichiro:android-observablescrollview:1.6.0'
implementation 'com.github.kabouzeid:RecyclerView-FastScroll:1.0.16-kmod'
diff --git a/app/src/main/assets/retro-changelog.html b/app/src/main/assets/retro-changelog.html
index f608e39b..8152c9ad 100644
--- a/app/src/main/assets/retro-changelog.html
+++ b/app/src/main/assets/retro-changelog.html
@@ -1 +1 @@
-
We're really sorry for Announcing this Retro Music is driving towards pure Android Material
Design guidelines we don't want any unnecessary UI elements that don't need for Music
player.
v3.2.100
- Fix crashing on Sleep timer
v3.2.000
- Implemented Artist image loading all thanks to VinylMusicPlayer
- Fixed buttons in Genre details
- Fixed color buttons in Album and Artist details screen
v3.1.900
- Added Play and Shuffle buttons on Songs list, Album Details, Artist Details, Playlist
Details etc.
- Home toolbar is semi transparent in Banner mode
- Added new Buy Retro Music pro in settings
- Improved dark color in Dark theme
v3.1.850
- Toolbar will be clickable for Search
v3.1.800
- Search bar CardView background
- Improve volume zero
- Now playing and Album theme picker rollback to dialog
- Fix sharing app link
- Fix scanning dialog
- Added settings icons for options
v3.1.700
- Cleaned internal code
- Removed full screen option
- Added Toolbar elevation
- To access menu either tap on Toolbar or Hamburger icon
- Fix back button not working on playing queue
- Fix crashing on What's New screen
- Fix lyrics dialog
- Changed toggles to line icons
- Custom UserImageView for loading user profile image
- Fix crashing on artist list for number format error
- Fix blacklist dialog crashing
- Rearranged icons and main menu access
- Fix some crashes when device is locked or background
- Folder screen have main options access
- Dialogs are now using Material Dialogs v3(BottomSheet)
- Fix Shuffle icon for Artist, Album, Genre and Playlist details
v3.1.400
- Removed sync lyrics for Android 5
- Fix Seek-bar color in settings
- Added keyboard to popup on search
- Added keyboard to popup on search
- Improved lock-screen behavior and UI
- Improved text appearance
- Fix bio text not showing in settings
- Fix not showing slider(blur, filter song) amount in settings
- Fix setting ringtone
- Fix file sharing crash
- Fix some crashes
- Fix playlist icon on small devices
- Fix empty lyrics text color
- Fix album cover background purple color in color theme
v3.1.300
- Fix rename playlist text color
- Fix same album showing in details page
- Fix lyrics text alignment on sync and lyrics reading improved
- Improved home sections loading
- Removed library options which are duplicated (it's available from profile menu)
- Replaced collapsing Fab with Android Floating Extended Fab
- Replaced home with for you
- Fixed profile image not loading in about
- Improved selecting user profile image
- Added bio to enter custom message
- Improved some UI screens
v3.1.240
- Fix Search not showing from home screen
- Fix Volume controls color issue
- Fix Seek bar alignment
- Added tiny theme
- Improved full theme appearances
- Now playing theme preview updated
- Fix composer error
- Bottom Options improved(internal)
v3.1.200
- Added composer sort and editing
- Fix Crash in Album tag editor while selecting options
- Added Filter song length
- Added Favourites playlist icon will be accent color
- Added Colorful settings icons
- Added Corners for dialog
v3.0.570
- Fix Album/Artist square image
- Fix Delete dialog text format
- Fix Profile picture not showing after coming back from folders
- Fix Play button color i Simple and Plain themes
- Fix Sleep timer dialog crashing
- Fix Share song dialog title and text
If you see entire app white or dark or black select same theme in settings to fix
FAQ's
*If you face any UI related issues you clear app data and cache, if its
not working try to
uninstall and install again.
\ No newline at end of file
+
We're really sorry for Announcing this Retro Music is driving towards pure Android Material
Design guidelines we don't want any unnecessary UI elements that don't need for Music
player.
v3.2.125
- Fix crashing on selecting profile picture
- Semi transparent color fix(s) on now playing themes
v3.2.120
- Fix crashing on choosing a theme
- Fix color theme selection without pro enabled
- Fix icon tint some places
v3.2.105
v3.2.100
- Fix crashing on Sleep timer
- Toolbar elevation removed added stroke instead
- Show empty indication for home
v3.2.000
- Implemented Artist image loading all thanks to VinylMusicPlayer
- Fixed buttons in Genre details
- Fixed color buttons in Album and Artist details screen
v3.1.900
- Added Play and Shuffle buttons on Songs list, Album Details, Artist Details, Playlist
Details etc.
- Home toolbar is semi transparent in Banner mode
- Added new Buy Retro Music pro in settings
- Improved dark color in Dark theme
v3.1.850
- Toolbar will be clickable for Search
v3.1.800
- Search bar CardView background
- Improve volume zero
- Now playing and Album theme picker rollback to dialog
- Fix sharing app link
- Fix scanning dialog
- Added settings icons for options
v3.1.700
- Cleaned internal code
- Removed full screen option
- Added Toolbar elevation
- To access menu either tap on Toolbar or Hamburger icon
- Fix back button not working on playing queue
- Fix crashing on What's New screen
- Fix lyrics dialog
- Changed toggles to line icons
- Custom UserImageView for loading user profile image
- Fix crashing on artist list for number format error
- Fix blacklist dialog crashing
- Rearranged icons and main menu access
- Fix some crashes when device is locked or background
- Folder screen have main options access
- Dialogs are now using Material Dialogs v3(BottomSheet)
- Fix Shuffle icon for Artist, Album, Genre and Playlist details
v3.1.400
- Removed sync lyrics for Android 5
- Fix Seek-bar color in settings
- Added keyboard to popup on search
- Added keyboard to popup on search
- Improved lock-screen behavior and UI
- Improved text appearance
- Fix bio text not showing in settings
- Fix not showing slider(blur, filter song) amount in settings
- Fix setting ringtone
- Fix file sharing crash
- Fix some crashes
- Fix playlist icon on small devices
- Fix empty lyrics text color
- Fix album cover background purple color in color theme
v3.1.300
- Fix rename playlist text color
- Fix same album showing in details page
- Fix lyrics text alignment on sync and lyrics reading improved
- Improved home sections loading
- Removed library options which are duplicated (it's available from profile menu)
- Replaced collapsing Fab with Android Floating Extended Fab
- Replaced home with for you
- Fixed profile image not loading in about
- Improved selecting user profile image
- Added bio to enter custom message
- Improved some UI screens
v3.1.240
- Fix Search not showing from home screen
- Fix Volume controls color issue
- Fix Seek bar alignment
- Added tiny theme
- Improved full theme appearances
- Now playing theme preview updated
- Fix composer error
- Bottom Options improved(internal)
v3.1.200
- Added composer sort and editing
- Fix Crash in Album tag editor while selecting options
- Added Filter song length
- Added Favourites playlist icon will be accent color
- Added Colorful settings icons
- Added Corners for dialog
v3.0.570
- Fix Album/Artist square image
- Fix Delete dialog text format
- Fix Profile picture not showing after coming back from folders
- Fix Play button color i Simple and Plain themes
- Fix Sleep timer dialog crashing
- Fix Share song dialog title and text
If you see entire app white or dark or black select same theme in settings to fix
FAQ's
*If you face any UI related issues you clear app data and cache, if its
not working try to
uninstall and install again.
\ No newline at end of file
diff --git a/app/src/main/java/code/name/monkey/retromusic/activities/AlbumDetailsActivity.kt b/app/src/main/java/code/name/monkey/retromusic/activities/AlbumDetailsActivity.kt
index 1835f39f..85d5e379 100644
--- a/app/src/main/java/code/name/monkey/retromusic/activities/AlbumDetailsActivity.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/activities/AlbumDetailsActivity.kt
@@ -1,6 +1,7 @@
package code.name.monkey.retromusic.activities
import android.content.Intent
+import android.content.res.ColorStateList
import android.graphics.Color
import android.os.Bundle
import android.transition.Slide
@@ -70,7 +71,7 @@ class AlbumDetailsActivity : AbsSlidingMusicPanelActivity(), AlbumDetailsContrac
setupWindowTransition()
super.onCreate(savedInstanceState)
toggleBottomNavigationView(true)
- collapsingToolbarLayout?.setBackgroundColor(ThemeStore.primaryColor(this))
+ contentContainer?.setCardBackgroundColor( ColorStateList.valueOf(ThemeStore.primaryColor(this)))
setLightNavigationBar(true)
setNavigationbarColorAuto()
@@ -111,7 +112,7 @@ class AlbumDetailsActivity : AbsSlidingMusicPanelActivity(), AlbumDetailsContrac
supportActionBar!!.title = null
val primaryColor = ThemeStore.primaryColor(this)
- TintHelper.setTintAuto(contentContainer!!, primaryColor, true)
+ //TintHelper.setTintAuto(contentContainer!!, primaryColor, true)
if (collapsingToolbarLayout != null) {
collapsingToolbarLayout!!.apply {
diff --git a/app/src/main/java/code/name/monkey/retromusic/activities/ArtistDetailActivity.kt b/app/src/main/java/code/name/monkey/retromusic/activities/ArtistDetailActivity.kt
index 9152abf5..ae378a42 100755
--- a/app/src/main/java/code/name/monkey/retromusic/activities/ArtistDetailActivity.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/activities/ArtistDetailActivity.kt
@@ -2,6 +2,7 @@ package code.name.monkey.retromusic.activities
import android.app.Activity
import android.content.Intent
+import android.content.res.ColorStateList
import android.graphics.Color
import android.graphics.drawable.Drawable
import android.os.Build
@@ -17,7 +18,10 @@ import androidx.recyclerview.widget.DefaultItemAnimator
import androidx.recyclerview.widget.GridLayoutManager
import androidx.recyclerview.widget.LinearLayoutManager
import code.name.monkey.appthemehelper.ThemeStore
-import code.name.monkey.appthemehelper.util.*
+import code.name.monkey.appthemehelper.util.ATHUtil
+import code.name.monkey.appthemehelper.util.ColorUtil
+import code.name.monkey.appthemehelper.util.MaterialUtil
+import code.name.monkey.appthemehelper.util.ToolbarContentTintHelper
import code.name.monkey.retromusic.R
import code.name.monkey.retromusic.activities.base.AbsSlidingMusicPanelActivity
import code.name.monkey.retromusic.adapter.album.AlbumAdapter
@@ -68,7 +72,8 @@ class ArtistDetailActivity : AbsSlidingMusicPanelActivity(), ArtistDetailContrac
setDrawUnderStatusBar()
setupWindowTransitions()
super.onCreate(savedInstanceState)
- collapsingToolbarLayout?.setBackgroundColor(ThemeStore.primaryColor(this))
+ //collapsingToolbarLayout?.setBackgroundColor(ThemeStore.primaryColor(this))
+ contentContainer?.setCardBackgroundColor(ColorStateList.valueOf(ThemeStore.primaryColor(this)))
toggleBottomNavigationView(true)
setNavigationbarColorAuto()
setLightNavigationBar(true)
@@ -114,7 +119,7 @@ class ArtistDetailActivity : AbsSlidingMusicPanelActivity(), ArtistDetailContrac
private fun setupToolbarMarginHeight() {
val primaryColor = ThemeStore.primaryColor(this)
- TintHelper.setTintAuto(contentContainer!!, primaryColor, true)
+
collapsingToolbarLayout?.let {
it.setContentScrimColor(primaryColor)
it.setStatusBarScrimColor(ColorUtil.darkenColor(primaryColor))
@@ -198,7 +203,7 @@ class ArtistDetailActivity : AbsSlidingMusicPanelActivity(), ArtistDetailContrac
}
private fun getArtist(): Artist {
- return this.artist;
+ return this.artist
}
private fun setArtist(artist: Artist) {
@@ -327,7 +332,7 @@ class ArtistDetailActivity : AbsSlidingMusicPanelActivity(), ArtistDetailContrac
R.id.action_reset_artist_image -> {
Toast.makeText(this@ArtistDetailActivity, resources.getString(R.string.updating),
Toast.LENGTH_SHORT).show()
- CustomArtistImageUtil.getInstance(this@ArtistDetailActivity).resetCustomArtistImage(artist!!)
+ CustomArtistImageUtil.getInstance(this@ArtistDetailActivity).resetCustomArtistImage(artist)
forceDownload = true
return true
}
diff --git a/app/src/main/java/code/name/monkey/retromusic/activities/UserInfoActivity.kt b/app/src/main/java/code/name/monkey/retromusic/activities/UserInfoActivity.kt
index 1b4dc5dd..5030e32d 100644
--- a/app/src/main/java/code/name/monkey/retromusic/activities/UserInfoActivity.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/activities/UserInfoActivity.kt
@@ -1,18 +1,20 @@
package code.name.monkey.retromusic.activities
import android.app.Activity
-import android.content.*
+import android.content.ContentUris
+import android.content.Context
+import android.content.ContextWrapper
+import android.content.Intent
import android.content.res.ColorStateList
import android.graphics.Bitmap
import android.net.Uri
import android.os.Bundle
import android.provider.DocumentsContract
-import android.provider.MediaStore
+import android.provider.MediaStore.Images.Media
import android.provider.MediaStore.Images.Media.getBitmap
import android.text.TextUtils
import android.view.MenuItem
import android.widget.Toast
-import androidx.core.content.FileProvider
import code.name.monkey.appthemehelper.ThemeStore
import code.name.monkey.appthemehelper.util.ColorUtil
import code.name.monkey.appthemehelper.util.MaterialUtil
@@ -56,10 +58,10 @@ class UserInfoActivity : AbsBaseActivity() {
name.setText(PreferenceUtil.getInstance().userName)
bio.setText(PreferenceUtil.getInstance().userBio)
- if (!PreferenceUtil.getInstance().profileImage.isEmpty()) {
+ if (PreferenceUtil.getInstance().profileImage.isNotEmpty()) {
loadImageFromStorage(PreferenceUtil.getInstance().profileImage)
}
- if (!PreferenceUtil.getInstance().bannerImage.isEmpty()) {
+ if (PreferenceUtil.getInstance().bannerImage.isNotEmpty()) {
loadBannerFromStorage(PreferenceUtil.getInstance().bannerImage)
}
userImage.setOnClickListener {
@@ -129,7 +131,7 @@ class UserInfoActivity : AbsBaseActivity() {
private fun selectBannerImage() {
if (TextUtils.isEmpty(PreferenceUtil.getInstance().bannerImage)) {
- val pickImageIntent = Intent(Intent.ACTION_PICK, MediaStore.Images.Media.EXTERNAL_CONTENT_URI)
+ val pickImageIntent = Intent(Intent.ACTION_PICK, Media.EXTERNAL_CONTENT_URI)
pickImageIntent.type = "image/*"
//pickImageIntent.putExtra("crop", "true")
pickImageIntent.putExtra("outputX", 1290)
@@ -147,7 +149,7 @@ class UserInfoActivity : AbsBaseActivity() {
private fun pickNewPhoto() {
- val pickImageIntent = Intent(Intent.ACTION_PICK, MediaStore.Images.Media.EXTERNAL_CONTENT_URI)
+ val pickImageIntent = Intent(Intent.ACTION_PICK, Media.EXTERNAL_CONTENT_URI)
pickImageIntent.type = "image/*"
pickImageIntent.putExtra("crop", "true")
pickImageIntent.putExtra("outputX", 512)
@@ -163,42 +165,30 @@ class UserInfoActivity : AbsBaseActivity() {
if (resultCode == Activity.RESULT_OK && data != null) {
when (requestCode) {
PICK_IMAGE_REQUEST -> {
- val uri = data.data
try {
- val bitmap = getResizedBitmap(getBitmap(contentResolver, uri), PROFILE_ICON_SIZE)
- val profileImagePath = saveToInternalStorage(bitmap, USER_PROFILE)
- PreferenceUtil.getInstance().saveProfileImage(profileImagePath)
- loadImageFromStorage(profileImagePath)
+ data.data?.let {
+ val bitmap = getResizedBitmap(getBitmap(contentResolver, it), PROFILE_ICON_SIZE)
+ val profileImagePath = saveToInternalStorage(bitmap, USER_PROFILE)
+ PreferenceUtil.getInstance().saveProfileImage(profileImagePath)
+ loadImageFromStorage(profileImagePath)
+ }
+
} catch (e: IOException) {
e.printStackTrace()
}
}
- CROP_IMAGE_REQUEST -> {
- val extras: Bundle = data.extras!!
- val selectedBitmap: Bitmap = extras.getParcelable("data")
- val profileImagePath = saveToInternalStorage(selectedBitmap, USER_PROFILE)
- PreferenceUtil.getInstance().saveProfileImage(profileImagePath)
- loadImageFromStorage(profileImagePath)
- }
PICK_BANNER_REQUEST -> {
- val uri = data.data
try {
- val bitmap = getBitmap(contentResolver, uri)
- val profileImagePath = saveToInternalStorage(bitmap, USER_BANNER)
- PreferenceUtil.getInstance().setBannerImagePath(profileImagePath)
- loadBannerFromStorage(profileImagePath)
+ data.data?.let {
+ val bitmap = getBitmap(contentResolver, it)
+ val profileImagePath = saveToInternalStorage(bitmap, USER_BANNER)
+ PreferenceUtil.getInstance().setBannerImagePath(profileImagePath)
+ loadBannerFromStorage(profileImagePath)
+ }
} catch (e: IOException) {
e.printStackTrace()
}
}
- CROP_BANNER_REQUEST -> {
- val selectedBitmap: Bitmap? = data.extras?.getParcelable("date")
- val profileImagePath = selectedBitmap?.let { saveToInternalStorage(it, USER_BANNER) }
- profileImagePath?.let {
- PreferenceUtil.getInstance().saveProfileImage(it)
- loadImageFromStorage(it)
- }
- }
}
}
}
@@ -213,8 +203,8 @@ class UserInfoActivity : AbsBaseActivity() {
val documentId = DocumentsContract.getDocumentId(aUri)
if ("com.android.providers.media.documents" == aUri.authority) {
val id = documentId.split(":".toRegex()).dropLastWhile { it.isEmpty() }.toTypedArray()[1]
- val selection = MediaStore.Images.Media._ID + "=" + id
- imagePath = getImagePath(MediaStore.Images.Media.EXTERNAL_CONTENT_URI, selection)
+ val selection = Media._ID + "=" + id
+ imagePath = getImagePath(Media.EXTERNAL_CONTENT_URI, selection)
} else if ("com.android.providers.downloads.documents" == aUri.authority) {
val contentUri = ContentUris.withAppendedId(Uri.parse("content://downloads/public_downloads"),
java.lang.Long.valueOf(documentId))
@@ -233,50 +223,13 @@ class UserInfoActivity : AbsBaseActivity() {
val cursor = App.context.contentResolver.query(aUri, null, aSelection, null, null)
if (cursor != null) {
if (cursor.moveToFirst()) {
- path = cursor.getString(cursor.getColumnIndex(MediaStore.Images.Media.DATA))
+ path = cursor.getString(cursor.getColumnIndex(Media.DATA))
}
cursor.close()
}
return path
}
- private fun performBannerCrop(picturePath: Uri?) {
- val photoUri = FileProvider.getUriForFile(this, "$packageName.provider", File(getImagePathFromUri(picturePath)))
- try {
-
- val cropIntent = Intent("com.android.camera.action.CROP")
- cropIntent.setDataAndType(photoUri, "image/*")
- cropIntent.putExtra("crop", "true")
- cropIntent.putExtra("aspectX", 1)
- cropIntent.putExtra("aspectY", 1)
- cropIntent.putExtra("return-data", true)
- cropIntent.addFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION)
- startActivityForResult(cropIntent, CROP_BANNER_REQUEST)
- } catch (anfe: ActivityNotFoundException) {
- val errorMessage = "your device doesn't support the crop action!"
- Toast.makeText(this, errorMessage, Toast.LENGTH_SHORT).show()
- }
- }
-
- private fun performCrop(imageUri: Uri) {
- val photoUri = FileProvider.getUriForFile(this, "$packageName.provider", File(getImagePathFromUri(imageUri)))
- try {
- val cropIntent = Intent("com.android.camera.action.CROP")
- cropIntent.setDataAndType(photoUri, "image/*")
- cropIntent.putExtra("crop", "true")
- cropIntent.putExtra("aspectX", 1)
- cropIntent.putExtra("aspectY", 1)
- cropIntent.putExtra("outputX", 280)
- cropIntent.putExtra("outputY", 280)
- cropIntent.putExtra("return-data", true)
- cropIntent.addFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION)
- startActivityForResult(cropIntent, CROP_IMAGE_REQUEST)
- } catch (anfe: ActivityNotFoundException) {
- val errorMessage = "your device doesn't support the crop action!"
- Toast.makeText(this, errorMessage, Toast.LENGTH_SHORT).show()
- }
- }
-
private fun loadBannerFromStorage(profileImagePath: String) {
disposable.add(Compressor(this)
.setQuality(100)
@@ -323,9 +276,7 @@ class UserInfoActivity : AbsBaseActivity() {
companion object {
private const val PICK_IMAGE_REQUEST = 9002
- private const val CROP_IMAGE_REQUEST = 9003
private const val PICK_BANNER_REQUEST = 9004
- private const val CROP_BANNER_REQUEST = 9005
private const val PROFILE_ICON_SIZE = 400
}
}
diff --git a/app/src/main/java/code/name/monkey/retromusic/activities/tageditor/WriteTagsAsyncTask.java b/app/src/main/java/code/name/monkey/retromusic/activities/tageditor/WriteTagsAsyncTask.java
index 8ead2b76..010a28f8 100644
--- a/app/src/main/java/code/name/monkey/retromusic/activities/tageditor/WriteTagsAsyncTask.java
+++ b/app/src/main/java/code/name/monkey/retromusic/activities/tageditor/WriteTagsAsyncTask.java
@@ -133,6 +133,7 @@ public class WriteTagsAsyncTask extends
(Activity) context, toBeScanned) : null);
}
+ @NonNull
@Override
protected Dialog createDialog(@NonNull Context context) {
return new MaterialDialog(context, new BottomSheet())
diff --git a/app/src/main/java/code/name/monkey/retromusic/adapter/HomeAdapter.kt b/app/src/main/java/code/name/monkey/retromusic/adapter/HomeAdapter.kt
index 3d770904..28f2ea3a 100644
--- a/app/src/main/java/code/name/monkey/retromusic/adapter/HomeAdapter.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/adapter/HomeAdapter.kt
@@ -1,15 +1,16 @@
package code.name.monkey.retromusic.adapter
+import android.content.res.ColorStateList
import android.util.DisplayMetrics
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
-import android.widget.TextView
import androidx.annotation.IntDef
import androidx.appcompat.app.AppCompatActivity
import androidx.recyclerview.widget.GridLayoutManager
import androidx.recyclerview.widget.LinearLayoutManager
import androidx.recyclerview.widget.RecyclerView
+import code.name.monkey.appthemehelper.ThemeStore
import code.name.monkey.retromusic.R
import code.name.monkey.retromusic.adapter.album.AlbumFullWidthAdapter
import code.name.monkey.retromusic.adapter.artist.ArtistAdapter
@@ -17,7 +18,7 @@ import code.name.monkey.retromusic.adapter.song.SongAdapter
import code.name.monkey.retromusic.loaders.PlaylistSongsLoader
import code.name.monkey.retromusic.model.*
import code.name.monkey.retromusic.util.PreferenceUtil
-import code.name.monkey.retromusic.views.IconImageView
+import com.google.android.material.chip.Chip
class HomeAdapter(private val activity: AppCompatActivity, private var homes: List, private val displayMetrics: DisplayMetrics) : RecyclerView.Adapter() {
@@ -91,8 +92,8 @@ class HomeAdapter(private val activity: AppCompatActivity, private var homes: Li
recyclerView.apply {
adapter = AlbumFullWidthAdapter(activity, home.arrayList as ArrayList, displayMetrics)
}
- title.text = activity.getString(home.title)
- icon.setImageResource(home.icon)
+ chip.text = activity.getString(home.title)
+ chip.setChipIconResource(home.icon)
}
}
@@ -103,8 +104,8 @@ class HomeAdapter(private val activity: AppCompatActivity, private var homes: Li
val artistAdapter = ArtistAdapter(activity, home.arrayList as ArrayList, PreferenceUtil.getInstance().getHomeGridStyle(context!!), false, null)
adapter = artistAdapter
}
- title.text = activity.getString(home.title)
- icon.setImageResource(home.icon)
+ chip.text = activity.getString(home.title)
+ chip.setChipIconResource(home.icon)
}
}
@@ -116,8 +117,8 @@ class HomeAdapter(private val activity: AppCompatActivity, private var homes: Li
adapter = genreAdapter
}
- title.text = activity.getString(home.title)
- icon.setImageResource(home.icon)
+ chip.text = activity.getString(home.title)
+ chip.setChipIconResource(home.icon)
}
}
@@ -130,14 +131,17 @@ class HomeAdapter(private val activity: AppCompatActivity, private var homes: Li
adapter = songAdapter
}
- title.text = activity.getString(home.title)
- icon.setImageResource(home.icon)
+ chip.text = activity.getString(home.title)
+ chip.setChipIconResource(home.icon)
}
}
private open inner class AbsHomeViewItem(itemView: View) : RecyclerView.ViewHolder(itemView) {
val recyclerView: RecyclerView = itemView.findViewById(R.id.recyclerView)
- val title: TextView = itemView.findViewById(R.id.sectionTitle)
- val icon: IconImageView = itemView.findViewById(R.id.sectionIcon)
+ val chip: Chip = itemView.findViewById(R.id.chipHead)
+
+ init {
+ chip.apply { chipBackgroundColor = ColorStateList.valueOf(ThemeStore.primaryColor(context)) }
+ }
}
}
\ No newline at end of file
diff --git a/app/src/main/java/code/name/monkey/retromusic/deezer/DeezerApiService.kt b/app/src/main/java/code/name/monkey/retromusic/deezer/DeezerApiService.kt
index 16a64bae..6378be4b 100644
--- a/app/src/main/java/code/name/monkey/retromusic/deezer/DeezerApiService.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/deezer/DeezerApiService.kt
@@ -52,12 +52,11 @@ interface DeezerApiService {
.addHeader("Cache-Control",
String.format(
Locale.getDefault(),
- "max-age=%d, max-stale=%d",
- 31536000, 31536000
+ "max-age=31536000, max-stale=31536000"
)
).build()
chain.proceed(modifiedRequest)
}
}
}
-}
\ No newline at end of file
+}
diff --git a/app/src/main/java/code/name/monkey/retromusic/extensions/ColorExt.kt b/app/src/main/java/code/name/monkey/retromusic/extensions/ColorExt.kt
new file mode 100644
index 00000000..51a9b9a2
--- /dev/null
+++ b/app/src/main/java/code/name/monkey/retromusic/extensions/ColorExt.kt
@@ -0,0 +1,21 @@
+/*
+ * Copyright (c) 2019 Hemanth Savarala.
+ *
+ * Licensed under the GNU General Public License v3
+ *
+ * This is free software: you can redistribute it and/or modify it under
+ * the terms of the GNU General Public License as published by
+ * the Free Software Foundation either version 3 of the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
+ * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+ * See the GNU General Public License for more details.
+ */
+
+package code.name.monkey.retromusic.extensions
+
+import code.name.monkey.appthemehelper.util.ColorUtil
+
+fun Int.ripAlpha(): Int {
+ return ColorUtil.stripAlpha(this)
+}
\ No newline at end of file
diff --git a/app/src/main/java/code/name/monkey/retromusic/fragments/VolumeFragment.kt b/app/src/main/java/code/name/monkey/retromusic/fragments/VolumeFragment.kt
index 4daa88b1..eaa1ad18 100755
--- a/app/src/main/java/code/name/monkey/retromusic/fragments/VolumeFragment.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/fragments/VolumeFragment.kt
@@ -12,6 +12,7 @@ import android.widget.SeekBar
import androidx.fragment.app.Fragment
import code.name.monkey.appthemehelper.ThemeStore
import code.name.monkey.appthemehelper.util.ATHUtil
+import code.name.monkey.appthemehelper.util.TintHelper
import code.name.monkey.retromusic.R
import code.name.monkey.retromusic.helper.MusicPlayerRemote
import code.name.monkey.retromusic.util.PreferenceUtil
@@ -109,7 +110,6 @@ class VolumeFragment : Fragment(), SeekBar.OnSeekBarChangeListener, OnAudioVolum
}
fun setTintable(color: Int) {
-
ViewUtil.setProgressDrawable(volumeSeekBar, color, true)
}
@@ -121,15 +121,12 @@ class VolumeFragment : Fragment(), SeekBar.OnSeekBarChangeListener, OnAudioVolum
if (PreferenceUtil.getInstance().pauseOnZeroVolume())
if (MusicPlayerRemote.isPlaying && pauseWhenZeroVolume) {
MusicPlayerRemote.pauseSong()
- } else {
- MusicPlayerRemote.resumePlaying()
}
}
fun setTintableColor(color: Int) {
volumeDown.setColorFilter(color, PorterDuff.Mode.SRC_IN)
volumeUp.setColorFilter(color, PorterDuff.Mode.SRC_IN)
- //TintHelper.setTintAuto(volumeSeekBar, color, false)
ViewUtil.setProgressDrawable(volumeSeekBar, color, true)
}
diff --git a/app/src/main/java/code/name/monkey/retromusic/fragments/mainactivity/AlbumsFragment.kt b/app/src/main/java/code/name/monkey/retromusic/fragments/mainactivity/AlbumsFragment.kt
index e8bb33ff..2cf5c322 100644
--- a/app/src/main/java/code/name/monkey/retromusic/fragments/mainactivity/AlbumsFragment.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/fragments/mainactivity/AlbumsFragment.kt
@@ -12,7 +12,7 @@ import code.name.monkey.retromusic.util.PreferenceUtil
open class AlbumsFragment : AbsLibraryPagerRecyclerViewCustomGridSizeFragment(), AlbumContract.AlbumView {
- private var presenter: AlbumPresenter? = null
+ private lateinit var presenter: AlbumPresenter
override val emptyMessage: Int
@@ -48,7 +48,7 @@ open class AlbumsFragment : AbsLibraryPagerRecyclerViewCustomGridSizeFragment(), ArtistContract.ArtistView {
- private var presenter: ArtistPresenter? = null
+ private lateinit var presenter: ArtistPresenter
override val emptyMessage: Int
get() = R.string.no_artists
@@ -37,7 +37,7 @@ class ArtistsFragment : AbsLibraryPagerRecyclerViewCustomGridSizeFragment(), PlaylistContract.PlaylistView {
- private var presenter: PlaylistPresenter? = null
+ private lateinit var presenter: PlaylistPresenter
override val emptyMessage: Int
get() = R.string.no_playlists
@@ -47,18 +47,18 @@ class PlaylistsFragment : AbsLibraryPagerRecyclerViewFragment bannerImage.setImageBitmap(bitmap) })
}
}
loadImageFromStorage()
diff --git a/app/src/main/java/code/name/monkey/retromusic/fragments/player/adaptive/AdaptivePlaybackControlsFragment.kt b/app/src/main/java/code/name/monkey/retromusic/fragments/player/adaptive/AdaptivePlaybackControlsFragment.kt
index 1cd64bb9..ed4cefb1 100644
--- a/app/src/main/java/code/name/monkey/retromusic/fragments/player/adaptive/AdaptivePlaybackControlsFragment.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/fragments/player/adaptive/AdaptivePlaybackControlsFragment.kt
@@ -14,6 +14,7 @@ import code.name.monkey.appthemehelper.util.ColorUtil
import code.name.monkey.appthemehelper.util.MaterialValueHelper
import code.name.monkey.appthemehelper.util.TintHelper
import code.name.monkey.retromusic.R
+import code.name.monkey.retromusic.extensions.ripAlpha
import code.name.monkey.retromusic.helper.MusicPlayerRemote
import code.name.monkey.retromusic.helper.MusicProgressViewUpdateHelper
import code.name.monkey.retromusic.helper.PlayPauseButtonOnClickHandler
@@ -100,7 +101,7 @@ class AdaptivePlaybackControlsFragment : AbsPlayerControlsFragment() {
val colorFinal = if (PreferenceUtil.getInstance().adaptiveColor) {
color
} else {
- ThemeStore.accentColor(context!!)
+ ThemeStore.accentColor(context!!).ripAlpha()
}
TintHelper.setTintAuto(playPauseButton, MaterialValueHelper.getPrimaryTextColor(context, ColorUtil.isColorLight(colorFinal)), false)
TintHelper.setTintAuto(playPauseButton, colorFinal, true)
diff --git a/app/src/main/java/code/name/monkey/retromusic/fragments/player/card/CardPlaybackControlsFragment.kt b/app/src/main/java/code/name/monkey/retromusic/fragments/player/card/CardPlaybackControlsFragment.kt
index 5954f6b2..923cef51 100644
--- a/app/src/main/java/code/name/monkey/retromusic/fragments/player/card/CardPlaybackControlsFragment.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/fragments/player/card/CardPlaybackControlsFragment.kt
@@ -14,6 +14,7 @@ import code.name.monkey.appthemehelper.util.ColorUtil
import code.name.monkey.appthemehelper.util.MaterialValueHelper
import code.name.monkey.appthemehelper.util.TintHelper
import code.name.monkey.retromusic.R
+import code.name.monkey.retromusic.extensions.ripAlpha
import code.name.monkey.retromusic.helper.MusicPlayerRemote
import code.name.monkey.retromusic.helper.MusicProgressViewUpdateHelper
import code.name.monkey.retromusic.helper.PlayPauseButtonOnClickHandler
@@ -127,7 +128,7 @@ class CardPlaybackControlsFragment : AbsPlayerControlsFragment() {
val colorFinal = if (PreferenceUtil.getInstance().adaptiveColor) {
color
} else {
- ThemeStore.accentColor(context!!)
+ ThemeStore.accentColor(context!!).ripAlpha()
}
image.setColorFilter(colorFinal, PorterDuff.Mode.SRC_IN)
TintHelper.setTintAuto(playPauseButton, MaterialValueHelper.getPrimaryTextColor(context, ColorUtil.isColorLight(colorFinal)), false)
diff --git a/app/src/main/java/code/name/monkey/retromusic/fragments/player/classic/ClassicPlayerFragment.kt b/app/src/main/java/code/name/monkey/retromusic/fragments/player/classic/ClassicPlayerFragment.kt
index 1776a224..886b9296 100644
--- a/app/src/main/java/code/name/monkey/retromusic/fragments/player/classic/ClassicPlayerFragment.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/fragments/player/classic/ClassicPlayerFragment.kt
@@ -16,16 +16,16 @@ import code.name.monkey.appthemehelper.ThemeStore
import code.name.monkey.appthemehelper.util.ATHUtil
import code.name.monkey.appthemehelper.util.ColorUtil
import code.name.monkey.retromusic.R
+import code.name.monkey.retromusic.activities.base.AbsSlidingMusicPanelActivity
+import code.name.monkey.retromusic.adapter.base.MediaEntryViewHolder
+import code.name.monkey.retromusic.adapter.song.PlayingQueueAdapter
import code.name.monkey.retromusic.dialogs.SongShareDialog
+import code.name.monkey.retromusic.fragments.base.AbsPlayerFragment
+import code.name.monkey.retromusic.fragments.player.PlayerAlbumCoverFragment
import code.name.monkey.retromusic.helper.MusicPlayerRemote
import code.name.monkey.retromusic.helper.menu.SongMenuHelper
import code.name.monkey.retromusic.model.Song
import code.name.monkey.retromusic.model.lyrics.Lyrics
-import code.name.monkey.retromusic.activities.base.AbsSlidingMusicPanelActivity
-import code.name.monkey.retromusic.adapter.base.MediaEntryViewHolder
-import code.name.monkey.retromusic.adapter.song.PlayingQueueAdapter
-import code.name.monkey.retromusic.fragments.base.AbsPlayerFragment
-import code.name.monkey.retromusic.fragments.player.PlayerAlbumCoverFragment
import code.name.monkey.retromusic.util.MusicUtil
import code.name.monkey.retromusic.util.RetroUtil
import code.name.monkey.retromusic.util.ViewUtil
@@ -151,8 +151,7 @@ class ClassicPlayerFragment : AbsPlayerFragment(), PlayerAlbumCoverFragment.Call
private fun setUpPlayerToolbar() {
playerToolbar.apply {
- inflateMenu(code.name.monkey.retromusic.R.menu.menu_player)
- setNavigationIcon(code.name.monkey.retromusic.R.drawable.ic_close_white_24dp)
+ inflateMenu(R.menu.menu_player)
setNavigationOnClickListener { activity!!.onBackPressed() }
setOnMenuItemClickListener(this@ClassicPlayerFragment)
}
diff --git a/app/src/main/java/code/name/monkey/retromusic/fragments/player/color/ColorPlaybackControlsFragment.kt b/app/src/main/java/code/name/monkey/retromusic/fragments/player/color/ColorPlaybackControlsFragment.kt
index 2be99a8d..2a916454 100644
--- a/app/src/main/java/code/name/monkey/retromusic/fragments/player/color/ColorPlaybackControlsFragment.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/fragments/player/color/ColorPlaybackControlsFragment.kt
@@ -15,14 +15,14 @@ import android.widget.SeekBar
import code.name.monkey.appthemehelper.util.ColorUtil
import code.name.monkey.appthemehelper.util.TintHelper
import code.name.monkey.retromusic.R
+import code.name.monkey.retromusic.fragments.base.AbsPlayerControlsFragment
import code.name.monkey.retromusic.helper.MusicPlayerRemote
import code.name.monkey.retromusic.helper.MusicProgressViewUpdateHelper
import code.name.monkey.retromusic.helper.PlayPauseButtonOnClickHandler
import code.name.monkey.retromusic.misc.SimpleOnSeekbarChangeListener
import code.name.monkey.retromusic.service.MusicService
-import code.name.monkey.retromusic.fragments.base.AbsPlayerControlsFragment
import code.name.monkey.retromusic.util.MusicUtil
-import kotlinx.android.synthetic.main.fragment_player_playback_controls.*
+import kotlinx.android.synthetic.main.fragment_color_player_playback_controls.*
import kotlinx.android.synthetic.main.media_button.*
class ColorPlaybackControlsFragment : AbsPlayerControlsFragment() {
@@ -99,7 +99,7 @@ class ColorPlaybackControlsFragment : AbsPlayerControlsFragment() {
title!!.setTextColor(lastPlaybackControlsColor)
text!!.setTextColor(lastDisabledPlaybackControlsColor)
- setProgressBarColor(lastPlaybackControlsColor, lastDisabledPlaybackControlsColor)
+ TintHelper.setTintAuto(progressSlider, lastPlaybackControlsColor, false)
volumeFragment?.setTintableColor(lastPlaybackControlsColor)
@@ -111,17 +111,6 @@ class ColorPlaybackControlsFragment : AbsPlayerControlsFragment() {
updatePrevNextColor()
}
- private fun setProgressBarColor(c1: Int, c2: Int) {
- progressSlider.thumbTintList = ColorStateList.valueOf(c1)
- val ld = progressSlider.progressDrawable as LayerDrawable
-
- val clipDrawableProgress = ld.findDrawableByLayerId(android.R.id.progress)
- clipDrawableProgress.setColorFilter(c1, PorterDuff.Mode.SRC_IN)
-
- val clipDrawableBackground = ld.findDrawableByLayerId(android.R.id.background)
- clipDrawableBackground.setColorFilter(c2, PorterDuff.Mode.SRC_IN)
- }
-
private fun setUpPlayPauseFab() {
TintHelper.setTintAuto(playPauseButton, Color.WHITE, true)
TintHelper.setTintAuto(playPauseButton, Color.BLACK, false)
diff --git a/app/src/main/java/code/name/monkey/retromusic/fragments/player/fit/FitPlaybackControlsFragment.kt b/app/src/main/java/code/name/monkey/retromusic/fragments/player/fit/FitPlaybackControlsFragment.kt
index 2d24d31c..fffa948f 100644
--- a/app/src/main/java/code/name/monkey/retromusic/fragments/player/fit/FitPlaybackControlsFragment.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/fragments/player/fit/FitPlaybackControlsFragment.kt
@@ -16,6 +16,7 @@ import code.name.monkey.appthemehelper.util.ColorUtil
import code.name.monkey.appthemehelper.util.MaterialValueHelper
import code.name.monkey.appthemehelper.util.TintHelper
import code.name.monkey.retromusic.R
+import code.name.monkey.retromusic.extensions.ripAlpha
import code.name.monkey.retromusic.helper.MusicPlayerRemote
import code.name.monkey.retromusic.helper.MusicProgressViewUpdateHelper
import code.name.monkey.retromusic.helper.PlayPauseButtonOnClickHandler
@@ -113,7 +114,7 @@ class FitPlaybackControlsFragment : AbsPlayerControlsFragment() {
val colorFinal = if (PreferenceUtil.getInstance().adaptiveColor) {
color
} else {
- ThemeStore.accentColor(context!!)
+ ThemeStore.accentColor(context!!).ripAlpha()
}
volumeFragment?.setTintable(colorFinal)
diff --git a/app/src/main/java/code/name/monkey/retromusic/fragments/player/flat/FlatPlaybackControlsFragment.kt b/app/src/main/java/code/name/monkey/retromusic/fragments/player/flat/FlatPlaybackControlsFragment.kt
index 0eee0793..3c56b1d5 100644
--- a/app/src/main/java/code/name/monkey/retromusic/fragments/player/flat/FlatPlaybackControlsFragment.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/fragments/player/flat/FlatPlaybackControlsFragment.kt
@@ -15,6 +15,7 @@ import code.name.monkey.appthemehelper.util.ColorUtil
import code.name.monkey.appthemehelper.util.MaterialValueHelper
import code.name.monkey.appthemehelper.util.TintHelper
import code.name.monkey.retromusic.R
+import code.name.monkey.retromusic.extensions.ripAlpha
import code.name.monkey.retromusic.helper.MusicPlayerRemote
import code.name.monkey.retromusic.helper.MusicProgressViewUpdateHelper
import code.name.monkey.retromusic.helper.MusicProgressViewUpdateHelper.Callback
@@ -102,7 +103,7 @@ class FlatPlaybackControlsFragment : AbsPlayerControlsFragment(), Callback {
val colorFinal = if (PreferenceUtil.getInstance().adaptiveColor) {
color
} else {
- ThemeStore.accentColor(context!!)
+ ThemeStore.accentColor(context!!).ripAlpha()
}
updateTextColors(colorFinal)
diff --git a/app/src/main/java/code/name/monkey/retromusic/fragments/player/full/FullPlaybackControlsFragment.kt b/app/src/main/java/code/name/monkey/retromusic/fragments/player/full/FullPlaybackControlsFragment.kt
index 9ca74482..46e00d13 100644
--- a/app/src/main/java/code/name/monkey/retromusic/fragments/player/full/FullPlaybackControlsFragment.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/fragments/player/full/FullPlaybackControlsFragment.kt
@@ -21,6 +21,7 @@ import code.name.monkey.appthemehelper.util.ColorUtil
import code.name.monkey.appthemehelper.util.MaterialValueHelper
import code.name.monkey.appthemehelper.util.TintHelper
import code.name.monkey.retromusic.R
+import code.name.monkey.retromusic.extensions.ripAlpha
import code.name.monkey.retromusic.helper.MusicPlayerRemote
import code.name.monkey.retromusic.helper.MusicProgressViewUpdateHelper
import code.name.monkey.retromusic.helper.PlayPauseButtonOnClickHandler
@@ -111,7 +112,7 @@ class FullPlaybackControlsFragment : AbsPlayerControlsFragment(), PopupMenu.OnMe
val colorFinal = if (PreferenceUtil.getInstance().adaptiveColor) {
color
} else {
- ThemeStore.accentColor(context!!)
+ ThemeStore.accentColor(context!!).ripAlpha()
}
volumeFragment?.setTintableColor(colorFinal)
text.setTextColor(colorFinal)
diff --git a/app/src/main/java/code/name/monkey/retromusic/fragments/player/full/FullPlayerFragment.kt b/app/src/main/java/code/name/monkey/retromusic/fragments/player/full/FullPlayerFragment.kt
index fa5c1132..0e42bcb8 100644
--- a/app/src/main/java/code/name/monkey/retromusic/fragments/player/full/FullPlayerFragment.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/fragments/player/full/FullPlayerFragment.kt
@@ -12,6 +12,8 @@ import code.name.monkey.appthemehelper.util.ToolbarContentTintHelper
import code.name.monkey.retromusic.R
import code.name.monkey.retromusic.extensions.hide
import code.name.monkey.retromusic.extensions.show
+import code.name.monkey.retromusic.fragments.base.AbsPlayerFragment
+import code.name.monkey.retromusic.fragments.player.PlayerAlbumCoverFragment
import code.name.monkey.retromusic.glide.GlideApp
import code.name.monkey.retromusic.glide.RetroGlideExtension
import code.name.monkey.retromusic.glide.RetroMusicColoredTarget
@@ -21,8 +23,6 @@ import code.name.monkey.retromusic.loaders.ArtistLoader
import code.name.monkey.retromusic.model.Song
import code.name.monkey.retromusic.model.lyrics.AbsSynchronizedLyrics
import code.name.monkey.retromusic.model.lyrics.Lyrics
-import code.name.monkey.retromusic.fragments.base.AbsPlayerFragment
-import code.name.monkey.retromusic.fragments.player.PlayerAlbumCoverFragment
import code.name.monkey.retromusic.util.NavigationUtil
import io.reactivex.android.schedulers.AndroidSchedulers
import io.reactivex.disposables.CompositeDisposable
@@ -66,11 +66,11 @@ class FullPlayerFragment : AbsPlayerFragment(), PlayerAlbumCoverFragment.Callbac
lyricsLine1.alpha = 1f
lyricsLine1.translationY = 0f
- lyricsLine1.animate().alpha(0f).translationY(-h).duration = VISIBILITY_ANIM_DURATION
+ lyricsLine1.animate().alpha(0f).translationY(-h).duration = VISIBILITY_ANIM_DURATION
lyricsLine2.alpha = 0f
lyricsLine2.translationY = h
- lyricsLine2.animate().alpha(1f).translationY(0f).duration = VISIBILITY_ANIM_DURATION
+ lyricsLine2.animate().alpha(1f).translationY(0f).duration = VISIBILITY_ANIM_DURATION
}
}
@@ -83,7 +83,7 @@ class FullPlayerFragment : AbsPlayerFragment(), PlayerAlbumCoverFragment.Callbac
}
private fun hideLyricsLayout() {
- lyricsLayout.animate().alpha(0f).setDuration( VISIBILITY_ANIM_DURATION).withEndAction(Runnable {
+ lyricsLayout.animate().alpha(0f).setDuration(VISIBILITY_ANIM_DURATION).withEndAction(Runnable {
if (!isLyricsLayoutBound()) return@Runnable
lyricsLayout.visibility = View.GONE
lyricsLine1.text = null
@@ -91,7 +91,7 @@ class FullPlayerFragment : AbsPlayerFragment(), PlayerAlbumCoverFragment.Callbac
})
}
- override fun setLyrics(l: Lyrics?) {
+ override fun setLyrics(l: Lyrics?) {
lyrics = l
if (!isLyricsLayoutBound()) return
@@ -105,7 +105,7 @@ class FullPlayerFragment : AbsPlayerFragment(), PlayerAlbumCoverFragment.Callbac
lyricsLine2.text = null
lyricsLayout.visibility = View.VISIBLE
- lyricsLayout.animate().alpha(1f).duration = VISIBILITY_ANIM_DURATION
+ lyricsLayout.animate().alpha(1f).duration = VISIBILITY_ANIM_DURATION
}
override fun playerToolbar(): Toolbar {
@@ -119,7 +119,6 @@ class FullPlayerFragment : AbsPlayerFragment(), PlayerAlbumCoverFragment.Callbac
private fun setUpPlayerToolbar() {
playerToolbar.apply {
- setNavigationIcon(R.drawable.ic_close_white_24dp)
setNavigationOnClickListener { activity!!.onBackPressed() }
}
}
diff --git a/app/src/main/java/code/name/monkey/retromusic/fragments/player/lockscreen/LockScreenPlayerControlsFragment.kt b/app/src/main/java/code/name/monkey/retromusic/fragments/player/lockscreen/LockScreenPlayerControlsFragment.kt
index 52511340..71621910 100644
--- a/app/src/main/java/code/name/monkey/retromusic/fragments/player/lockscreen/LockScreenPlayerControlsFragment.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/fragments/player/lockscreen/LockScreenPlayerControlsFragment.kt
@@ -29,6 +29,7 @@ import code.name.monkey.appthemehelper.util.ColorUtil
import code.name.monkey.appthemehelper.util.MaterialValueHelper
import code.name.monkey.appthemehelper.util.TintHelper
import code.name.monkey.retromusic.R
+import code.name.monkey.retromusic.extensions.ripAlpha
import code.name.monkey.retromusic.helper.MusicPlayerRemote
import code.name.monkey.retromusic.helper.MusicProgressViewUpdateHelper
import code.name.monkey.retromusic.helper.PlayPauseButtonOnClickHandler
@@ -123,7 +124,7 @@ class LockScreenPlayerControlsFragment : AbsPlayerControlsFragment() {
val colorFinal = if (PreferenceUtil.getInstance().adaptiveColor) {
color
} else {
- ThemeStore.textColorSecondary(context!!)
+ ThemeStore.textColorSecondary(context!!).ripAlpha()
}
volumeFragment?.setTintable(colorFinal)
ViewUtil.setProgressDrawable(progressSlider, ColorUtil.stripAlpha(colorFinal), true)
diff --git a/app/src/main/java/code/name/monkey/retromusic/fragments/player/material/MaterialControlsFragment.kt b/app/src/main/java/code/name/monkey/retromusic/fragments/player/material/MaterialControlsFragment.kt
index 96e66e28..091d7ec1 100644
--- a/app/src/main/java/code/name/monkey/retromusic/fragments/player/material/MaterialControlsFragment.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/fragments/player/material/MaterialControlsFragment.kt
@@ -13,6 +13,7 @@ import code.name.monkey.appthemehelper.util.ATHUtil
import code.name.monkey.appthemehelper.util.ColorUtil
import code.name.monkey.appthemehelper.util.MaterialValueHelper
import code.name.monkey.retromusic.R
+import code.name.monkey.retromusic.extensions.ripAlpha
import code.name.monkey.retromusic.helper.MusicPlayerRemote
import code.name.monkey.retromusic.helper.MusicProgressViewUpdateHelper
import code.name.monkey.retromusic.helper.PlayPauseButtonOnClickHandler
@@ -106,7 +107,7 @@ class MaterialControlsFragment : AbsPlayerControlsFragment() {
lastPlaybackControlsColor = color
color
} else {
- ThemeStore.textColorSecondary(context!!)
+ ThemeStore.textColorSecondary(context!!).ripAlpha()
}
text.setTextColor(colorFinal)
ViewUtil.setProgressDrawable(progressSlider, ColorUtil.stripAlpha(colorFinal), true)
diff --git a/app/src/main/java/code/name/monkey/retromusic/fragments/player/normal/PlayerFragment.kt b/app/src/main/java/code/name/monkey/retromusic/fragments/player/normal/PlayerFragment.kt
index dfea11f7..f0eb0203 100644
--- a/app/src/main/java/code/name/monkey/retromusic/fragments/player/normal/PlayerFragment.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/fragments/player/normal/PlayerFragment.kt
@@ -101,7 +101,6 @@ class PlayerFragment : AbsPlayerFragment(), PlayerAlbumCoverFragment.Callbacks {
super.onViewCreated(view, savedInstanceState)
setUpSubFragments()
setUpPlayerToolbar()
- snowfall.visibility = if (PreferenceUtil.getInstance().isSnowFall) View.VISIBLE else View.GONE
//val display = activity?.windowManager?.defaultDisplay
diff --git a/app/src/main/java/code/name/monkey/retromusic/fragments/player/normal/PlayerPlaybackControlsFragment.kt b/app/src/main/java/code/name/monkey/retromusic/fragments/player/normal/PlayerPlaybackControlsFragment.kt
index 3c445d7f..77583ede 100644
--- a/app/src/main/java/code/name/monkey/retromusic/fragments/player/normal/PlayerPlaybackControlsFragment.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/fragments/player/normal/PlayerPlaybackControlsFragment.kt
@@ -15,6 +15,7 @@ import code.name.monkey.appthemehelper.util.ColorUtil
import code.name.monkey.appthemehelper.util.MaterialValueHelper
import code.name.monkey.appthemehelper.util.TintHelper
import code.name.monkey.retromusic.R
+import code.name.monkey.retromusic.extensions.ripAlpha
import code.name.monkey.retromusic.helper.MusicPlayerRemote
import code.name.monkey.retromusic.helper.MusicProgressViewUpdateHelper
import code.name.monkey.retromusic.helper.PlayPauseButtonOnClickHandler
@@ -71,10 +72,9 @@ class PlayerPlaybackControlsFragment : AbsPlayerControlsFragment() {
val colorFinal = if (PreferenceUtil.getInstance().adaptiveColor) {
color
} else {
- ThemeStore.accentColor(context!!)
+ ThemeStore.accentColor(context!!).ripAlpha()
}
-
TintHelper.setTintAuto(playPauseButton, MaterialValueHelper.getPrimaryTextColor(context!!, ColorUtil.isColorLight(colorFinal)), false)
TintHelper.setTintAuto(playPauseButton, colorFinal, true)
ViewUtil.setProgressDrawable(progressSlider, colorFinal)
diff --git a/app/src/main/java/code/name/monkey/retromusic/fragments/settings/AbsSettingsFragment.kt b/app/src/main/java/code/name/monkey/retromusic/fragments/settings/AbsSettingsFragment.kt
index 4e2c15ac..7a9eee1e 100644
--- a/app/src/main/java/code/name/monkey/retromusic/fragments/settings/AbsSettingsFragment.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/fragments/settings/AbsSettingsFragment.kt
@@ -33,18 +33,12 @@ import code.name.monkey.retromusic.util.NavigationUtil
*/
abstract class AbsSettingsFragment : PreferenceFragmentCompat() {
+
internal fun showProToastAndNavigate(message: String) {
Toast.makeText(context, "$message is Pro version feature.", Toast.LENGTH_SHORT).show()
-
NavigationUtil.goToProVersion(activity!!)
}
- protected fun setSummary(preference: Preference) {
- setSummary(preference, PreferenceManager
- .getDefaultSharedPreferences(preference.context)
- .getString(preference.key, "")!!)
- }
-
internal fun setSummary(preference: Preference, value: Any) {
val stringValue = value.toString()
if (preference is ListPreference) {
@@ -57,6 +51,12 @@ abstract class AbsSettingsFragment : PreferenceFragmentCompat() {
abstract fun invalidateSettings()
+ protected fun setSummary(preference: Preference) {
+ setSummary(preference, PreferenceManager
+ .getDefaultSharedPreferences(preference.context)
+ .getString(preference.key, "")!!)
+ }
+
override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
super.onViewCreated(view, savedInstanceState)
setDivider(ColorDrawable(Color.TRANSPARENT))
@@ -68,19 +68,18 @@ abstract class AbsSettingsFragment : PreferenceFragmentCompat() {
}
override fun onDisplayPreferenceDialog(preference: Preference) {
- var dialogFragment: DialogFragment? = null
- if (preference is NowPlayingScreenPreference) {
- dialogFragment = NowPlayingScreenPreferenceDialog.newInstance(preference.key);
- } else if (preference is AlbumCoverStylePreference) {
- dialogFragment = AlbumCoverStylePreferenceDialog.newInstance(preference.key);
- }
- if (preference is MaterialListPreference) {
- preference.entries
- dialogFragment = MaterialListPreferenceDialog.newInstance(preference)
- }
- if (preference is BlacklistPreference) {
- dialogFragment = BlacklistPreferenceDialog.newInstance(preference.key)
+ var dialogFragment: DialogFragment? = null// Dialog creation could not be handled here. Try with the super method.
+ // The dialog was created (it was one of our custom Preferences), show the dialog for it
+ when (preference) {
+ is NowPlayingScreenPreference -> dialogFragment = NowPlayingScreenPreferenceDialog.newInstance(preference.key)
+ is AlbumCoverStylePreference -> dialogFragment = AlbumCoverStylePreferenceDialog.newInstance(preference.key)
+ is MaterialListPreference -> {
+ preference.entries
+ dialogFragment = MaterialListPreferenceDialog.newInstance(preference)
+ }
+ is BlacklistPreference -> dialogFragment = BlacklistPreferenceDialog.newInstance(preference.key)
}
+
if (dialogFragment != null) {
// The dialog was created (it was one of our custom Preferences), show the dialog for it
dialogFragment.setTargetFragment(this, 0);
@@ -89,6 +88,5 @@ abstract class AbsSettingsFragment : PreferenceFragmentCompat() {
// Dialog creation could not be handled here. Try with the super method.
super.onDisplayPreferenceDialog(preference);
}
-
}
}
diff --git a/app/src/main/java/code/name/monkey/retromusic/fragments/settings/NotificationSettingsFragment.kt b/app/src/main/java/code/name/monkey/retromusic/fragments/settings/NotificationSettingsFragment.kt
index f2c6f065..aa99347c 100644
--- a/app/src/main/java/code/name/monkey/retromusic/fragments/settings/NotificationSettingsFragment.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/fragments/settings/NotificationSettingsFragment.kt
@@ -14,40 +14,50 @@
package code.name.monkey.retromusic.fragments.settings
-import android.os.Build
+import android.os.Build.VERSION
+import android.os.Build.VERSION_CODES
import android.os.Bundle
import androidx.preference.TwoStatePreference
-import code.name.monkey.retromusic.R
-import code.name.monkey.retromusic.helper.MusicPlayerRemote
import code.name.monkey.retromusic.util.PreferenceUtil
+
/**
* @author Hemanth S (h4h13).
*/
class NotificationSettingsFragment : AbsSettingsFragment() {
override fun invalidateSettings() {
- val classicNotification: TwoStatePreference = findPreference("classic_notification")!!
- if (Build.VERSION.SDK_INT < Build.VERSION_CODES.N) {
- classicNotification.isVisible = false
+
+ val classicNotification: TwoStatePreference? = findPreference("classic_notification")
+ if (VERSION.SDK_INT < VERSION_CODES.N) {
+ classicNotification?.isVisible = false
} else {
- classicNotification.isChecked = PreferenceUtil.getInstance().classicNotification()
- classicNotification.setOnPreferenceChangeListener { _, newValue ->
- // Save preference
- PreferenceUtil.getInstance().setClassicNotification(newValue as Boolean)
-
- val service = MusicPlayerRemote.musicService
- if (service != null) {
- service.initNotification()
- service.updateNotification()
+ classicNotification?.apply {
+ isChecked = PreferenceUtil.getInstance().classicNotification()
+ setOnPreferenceChangeListener { _, newValue ->
+ // Save preference
+ PreferenceUtil.getInstance().setClassicNotification(newValue as Boolean)
+ invalidateSettings()
+ true
}
+ }
+ }
- true
+ val coloredNotification: TwoStatePreference? = findPreference("colored_notification")
+ if (VERSION.SDK_INT >= VERSION_CODES.O) {
+ coloredNotification?.isEnabled = PreferenceUtil.getInstance().classicNotification()
+ } else {
+ coloredNotification?.apply {
+ isChecked = PreferenceUtil.getInstance().coloredNotification()
+ setOnPreferenceChangeListener { _, newValue ->
+ PreferenceUtil.getInstance().setColoredNotification(newValue as Boolean)
+ true
+ }
}
}
}
override fun onCreatePreferences(savedInstanceState: Bundle?, rootKey: String?) {
- addPreferencesFromResource(R.xml.pref_notification)
+ addPreferencesFromResource(code.name.monkey.retromusic.R.xml.pref_notification)
}
}
diff --git a/app/src/main/java/code/name/monkey/retromusic/fragments/settings/ThemeSettingsFragment.kt b/app/src/main/java/code/name/monkey/retromusic/fragments/settings/ThemeSettingsFragment.kt
index 24f829a3..ef2a62f3 100644
--- a/app/src/main/java/code/name/monkey/retromusic/fragments/settings/ThemeSettingsFragment.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/fragments/settings/ThemeSettingsFragment.kt
@@ -23,7 +23,6 @@ import androidx.preference.Preference
import androidx.preference.TwoStatePreference
import code.name.monkey.appthemehelper.*
import code.name.monkey.appthemehelper.common.prefs.supportv7.ATEColorPreference
-import code.name.monkey.appthemehelper.util.ATHUtil
import code.name.monkey.appthemehelper.util.ColorUtil
import code.name.monkey.appthemehelper.util.VersionUtils
import code.name.monkey.retromusic.App
@@ -42,68 +41,72 @@ import com.afollestad.materialdialogs.color.colorChooser
class ThemeSettingsFragment : AbsSettingsFragment() {
override fun invalidateSettings() {
- val primaryColorPref: ATEColorPreference = findPreference("primary_color")!!
- primaryColorPref.isVisible = PreferenceUtil.getInstance().generalTheme == R.style.Theme_RetroMusic_Color
- val primaryColor = ThemeStore.primaryColor(activity!!)
- primaryColorPref.setColor(primaryColor, ColorUtil.darkenColor(primaryColor))
- primaryColorPref.setOnPreferenceClickListener {
- MaterialDialog(activity!!, BottomSheet()).show {
- title(code.name.monkey.retromusic.R.string.primary_color)
- positiveButton(R.string.set)
- colorChooser(initialSelection = BLUE, allowCustomArgb = true, colors = PRIMARY_COLORS, subColors = PRIMARY_COLORS_SUB) { _, color ->
- val theme = if (ColorUtil.isColorLight(color))
- PreferenceUtil.getThemeResFromPrefValue("light")
- else
- PreferenceUtil.getThemeResFromPrefValue("dark")
+ val primaryColorPref: ATEColorPreference? = findPreference("primary_color")
+ primaryColorPref?.let {
+ it.isVisible = PreferenceUtil.getInstance().generalTheme == R.style.Theme_RetroMusic_Color
+ val primaryColor = ThemeStore.primaryColor(activity!!)
+ it.setColor(primaryColor, ColorUtil.darkenColor(primaryColor))
+ it.setOnPreferenceClickListener {
+ MaterialDialog(activity!!, BottomSheet()).show {
+ title(R.string.primary_color)
+ positiveButton(R.string.set)
+ colorChooser(initialSelection = BLUE,
+ allowCustomArgb = true,
+ colors = PRIMARY_COLORS,
+ subColors = PRIMARY_COLORS_SUB) { _, color ->
- ThemeStore.editTheme(context).activityTheme(theme).primaryColor(color).commit()
+ val theme = if (ColorUtil.isColorLight(color))
+ PreferenceUtil.getThemeResFromPrefValue("light")
+ else
+ PreferenceUtil.getThemeResFromPrefValue("dark")
- if (VersionUtils.hasNougatMR())
- DynamicShortcutManager(context).updateDynamicShortcuts()
- activity!!.recreate()
+ ThemeStore.editTheme(context).activityTheme(theme).primaryColor(color).commit()
+
+ if (VersionUtils.hasNougatMR())
+ DynamicShortcutManager(context).updateDynamicShortcuts()
+ activity!!.recreate()
+ }
}
+ true
}
- true
}
- val generalTheme: Preference = findPreference("general_theme")!!
- setSummary(generalTheme)
- generalTheme.setOnPreferenceChangeListener { _, newValue ->
- val theme = newValue as String
+ val generalTheme: Preference? = findPreference("general_theme")
- if (theme == "color" && !App.isProVersion) {
- primaryColorPref.isVisible = false
- showProToastAndNavigate("Color theme")
- return@setOnPreferenceChangeListener false
- } else {
- primaryColorPref.isVisible = true
- }
-
- setSummary(generalTheme, newValue)
-
-
- when (theme) {
- "light" -> ThemeStore.editTheme(context!!).primaryColor(Color.WHITE).commit()
- "black" -> ThemeStore.editTheme(context!!).primaryColor(Color.BLACK).commit()
- "dark" -> ThemeStore.editTheme(context!!).primaryColor(ContextCompat.getColor(context!!, R.color.md_grey_900)).commit()
- "daynight" -> {
- val color = ATHUtil.resolveColor(context!!, android.R.attr.colorPrimary)
- ThemeStore.editTheme(context!!).primaryColor(color).commit()
+ generalTheme?.let {
+ setSummary(it)
+ it.setOnPreferenceChangeListener { _, newValue ->
+ val theme = newValue as String
+ println(newValue)
+ if (theme == "color" && !App.isProVersion) {
+ showProToastAndNavigate("Color theme")
+ return@setOnPreferenceChangeListener false
}
- "color" -> ThemeStore.editTheme(context!!).primaryColor(ContextCompat.getColor(context!!, R.color.md_blue_grey_800)).commit()
- }
- ThemeStore.editTheme(activity!!)
- .activityTheme(PreferenceUtil.getThemeResFromPrefValue(theme))
- .commit()
+ if (theme == "color") {
+ primaryColorPref?.isVisible = true
+ }
- if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N_MR1) {
- activity!!.setTheme(PreferenceUtil.getThemeResFromPrefValue(theme))
- DynamicShortcutManager(activity!!).updateDynamicShortcuts()
+ setSummary(generalTheme, newValue)
+
+ when (theme) {
+ "light" -> ThemeStore.editTheme(context!!).primaryColor(Color.WHITE).commit()
+ "black" -> ThemeStore.editTheme(context!!).primaryColor(Color.BLACK).commit()
+ "dark" -> ThemeStore.editTheme(context!!).primaryColor(ContextCompat.getColor(context!!, R.color.md_grey_900)).commit()
+ "color" -> ThemeStore.editTheme(context!!).primaryColor(ContextCompat.getColor(context!!, R.color.md_blue_grey_800)).commit()
+ }
+
+ ThemeStore.editTheme(activity!!)
+ .activityTheme(PreferenceUtil.getThemeResFromPrefValue(theme))
+ .commit()
+
+ if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N_MR1) {
+ activity?.setTheme(PreferenceUtil.getThemeResFromPrefValue(theme))
+ DynamicShortcutManager(activity!!).updateDynamicShortcuts()
+ }
+ activity?.recreate()
+ true
}
- activity!!.recreate()
- //invalidateSettings();
- true
}
val accentColorPref: ATEColorPreference = findPreference("accent_color")!!
diff --git a/app/src/main/java/code/name/monkey/retromusic/model/AbsCustomPlaylist.java b/app/src/main/java/code/name/monkey/retromusic/model/AbsCustomPlaylist.java
index 07ea3140..031e48c6 100644
--- a/app/src/main/java/code/name/monkey/retromusic/model/AbsCustomPlaylist.java
+++ b/app/src/main/java/code/name/monkey/retromusic/model/AbsCustomPlaylist.java
@@ -17,9 +17,10 @@ package code.name.monkey.retromusic.model;
import android.content.Context;
import android.os.Parcel;
+import androidx.annotation.NonNull;
+
import java.util.ArrayList;
-import androidx.annotation.NonNull;
import io.reactivex.Observable;
/**
diff --git a/app/src/main/java/code/name/monkey/retromusic/mvp/contract/HomeContract.kt b/app/src/main/java/code/name/monkey/retromusic/mvp/contract/HomeContract.kt
index 34e84795..73e45e44 100644
--- a/app/src/main/java/code/name/monkey/retromusic/mvp/contract/HomeContract.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/mvp/contract/HomeContract.kt
@@ -20,12 +20,9 @@ import code.name.monkey.retromusic.mvp.BaseView
interface HomeContract {
- interface HomeView : BaseView> {
- fun showEmpty()
- }
+ interface HomeView : BaseView>
interface HomePresenter : BasePresenter {
-
- fun homeSections();
+ fun homeSections()
}
}
\ No newline at end of file
diff --git a/app/src/main/java/code/name/monkey/retromusic/mvp/presenter/HomePresenter.kt b/app/src/main/java/code/name/monkey/retromusic/mvp/presenter/HomePresenter.kt
index c8020fdd..83cb6f54 100644
--- a/app/src/main/java/code/name/monkey/retromusic/mvp/presenter/HomePresenter.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/mvp/presenter/HomePresenter.kt
@@ -59,7 +59,7 @@ class HomePresenter(private val view: HomeContract.HomeView) : Presenter(), Home
if (it.isNotEmpty()) hashSet.add(Home(0, R.string.recent_artists, 0, it, RECENT_ARTISTS, R.drawable.ic_artist_white_24dp))
view.showData(ArrayList(hashSet))
}, {
- view.showEmpty()
+ view.showEmptyView()
})
}
@@ -69,7 +69,7 @@ class HomePresenter(private val view: HomeContract.HomeView) : Presenter(), Home
if (it.isNotEmpty()) hashSet.add(Home(1, R.string.recent_albums, 0, it, RECENT_ALBUMS, R.drawable.ic_album_white_24dp))
view.showData(ArrayList(hashSet))
}, {
- view.showEmpty()
+ view.showEmptyView()
})
}
@@ -79,7 +79,7 @@ class HomePresenter(private val view: HomeContract.HomeView) : Presenter(), Home
if (it.isNotEmpty()) hashSet.add(Home(3, R.string.top_albums, 0, it, TOP_ALBUMS, R.drawable.ic_album_white_24dp))
view.showData(ArrayList(hashSet))
}, {
- view.showEmpty()
+ view.showEmptyView()
})
}
@@ -89,7 +89,7 @@ class HomePresenter(private val view: HomeContract.HomeView) : Presenter(), Home
if (it.isNotEmpty()) hashSet.add(Home(2, R.string.top_artists, 0, it, TOP_ARTISTS, R.drawable.ic_artist_white_24dp))
view.showData(ArrayList(hashSet))
}, {
- view.showEmpty()
+ view.showEmptyView()
})
}
@@ -99,7 +99,7 @@ class HomePresenter(private val view: HomeContract.HomeView) : Presenter(), Home
if (it.isNotEmpty()) hashSet.add(Home(4, R.string.favorites, 0, it, PLAYLISTS, R.drawable.ic_favorite_white_24dp))
view.showData(ArrayList(hashSet))
}, {
- view.showEmpty()
+ view.showEmptyView()
})
}
@@ -109,7 +109,7 @@ class HomePresenter(private val view: HomeContract.HomeView) : Presenter(), Home
if (it.isNotEmpty()) hashSet.add(Home(6, R.string.genres, 0, it, GENRES, R.drawable.ic_guitar_acoustic_white_24dp))
view.showData(ArrayList(hashSet))
}, {
- view.showEmpty()
+ view.showEmptyView()
})
}
}
diff --git a/app/src/main/java/code/name/monkey/retromusic/preferences/NowPlayingScreenPreferenceDialog.kt b/app/src/main/java/code/name/monkey/retromusic/preferences/NowPlayingScreenPreferenceDialog.kt
index 25d6c398..aa4110c6 100644
--- a/app/src/main/java/code/name/monkey/retromusic/preferences/NowPlayingScreenPreferenceDialog.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/preferences/NowPlayingScreenPreferenceDialog.kt
@@ -16,6 +16,7 @@ package code.name.monkey.retromusic.preferences
import android.app.Dialog
import android.content.Context
+import android.graphics.PorterDuff
import android.os.Bundle
import android.util.AttributeSet
import android.view.LayoutInflater
@@ -28,6 +29,7 @@ import androidx.preference.DialogPreference
import androidx.preference.PreferenceDialogFragmentCompat
import androidx.viewpager.widget.PagerAdapter
import androidx.viewpager.widget.ViewPager
+import code.name.monkey.appthemehelper.ThemeStore
import code.name.monkey.retromusic.App
import code.name.monkey.retromusic.R
import code.name.monkey.retromusic.fragments.NowPlayingScreen
@@ -35,7 +37,6 @@ import code.name.monkey.retromusic.util.NavigationUtil
import code.name.monkey.retromusic.util.PreferenceUtil
import code.name.monkey.retromusic.util.ViewUtil
import com.afollestad.materialdialogs.MaterialDialog
-import com.afollestad.materialdialogs.bottomsheets.BottomSheet
import com.afollestad.materialdialogs.customview.customView
import com.bumptech.glide.Glide
@@ -54,6 +55,10 @@ class NowPlayingScreenPreference : DialogPreference {
override fun getDialogLayoutResource(): Int {
return mLayoutRes;
}
+
+ init {
+ icon?.setColorFilter(ThemeStore.textColorSecondary(context), PorterDuff.Mode.SRC_IN)
+ }
}
class NowPlayingScreenPreferenceDialog : PreferenceDialogFragmentCompat(), ViewPager.OnPageChangeListener {
diff --git a/app/src/main/java/code/name/monkey/retromusic/service/MediaButtonIntentReceiver.kt b/app/src/main/java/code/name/monkey/retromusic/service/MediaButtonIntentReceiver.kt
index b48f34dc..ab0c95d9 100644
--- a/app/src/main/java/code/name/monkey/retromusic/service/MediaButtonIntentReceiver.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/service/MediaButtonIntentReceiver.kt
@@ -51,11 +51,11 @@ class MediaButtonIntentReceiver : BroadcastReceiver() {
}
companion object {
- val TAG = MediaButtonIntentReceiver::class.java.simpleName
+ val TAG: String = MediaButtonIntentReceiver::class.java.simpleName
private val DEBUG = BuildConfig.DEBUG
- private val MSG_HEADSET_DOUBLE_CLICK_TIMEOUT = 2
+ private const val MSG_HEADSET_DOUBLE_CLICK_TIMEOUT = 2
- private val DOUBLE_CLICK = 400
+ private const val DOUBLE_CLICK = 400
private var wakeLock: WakeLock? = null
private var mClickCounter = 0
diff --git a/app/src/main/java/code/name/monkey/retromusic/service/MusicService.java b/app/src/main/java/code/name/monkey/retromusic/service/MusicService.java
index 4db87c68..8155bf1c 100644
--- a/app/src/main/java/code/name/monkey/retromusic/service/MusicService.java
+++ b/app/src/main/java/code/name/monkey/retromusic/service/MusicService.java
@@ -29,7 +29,6 @@ import android.graphics.Point;
import android.graphics.drawable.Drawable;
import android.media.AudioManager;
import android.media.audiofx.AudioEffect;
-import android.media.session.MediaSession;
import android.os.Binder;
import android.os.Build;
import android.os.Handler;
@@ -86,6 +85,7 @@ import code.name.monkey.retromusic.service.playback.Playback;
import code.name.monkey.retromusic.util.MusicUtil;
import code.name.monkey.retromusic.util.PreferenceUtil;
import code.name.monkey.retromusic.util.RetroUtil;
+import io.reactivex.schedulers.Schedulers;
import static code.name.monkey.retromusic.Constants.ACTION_PAUSE;
import static code.name.monkey.retromusic.Constants.ACTION_PENDING_QUIT;
@@ -142,6 +142,7 @@ public class MusicService extends Service implements SharedPreferences.OnSharedP
| PlaybackStateCompat.ACTION_STOP
| PlaybackStateCompat.ACTION_SEEK_TO;
private final IBinder musicBind = new MusicBinder();
+ public boolean pendingQuit = false;
private AppWidgetBig appWidgetBig = AppWidgetBig.Companion.getInstance();
private AppWidgetClassic appWidgetClassic = AppWidgetClassic.Companion.getInstance();
private AppWidgetSmall appWidgetSmall = AppWidgetSmall.Companion.getInstance();
@@ -178,7 +179,6 @@ public class MusicService extends Service implements SharedPreferences.OnSharedP
}
};
- public boolean pendingQuit = false;
private Playback playback;
private ArrayList playingQueue = new ArrayList<>();
private ArrayList originalPlayingQueue = new ArrayList<>();
@@ -244,20 +244,18 @@ public class MusicService extends Service implements SharedPreferences.OnSharedP
public void onReceive(Context context, Intent intent) {
String action = intent.getAction();
if (action != null) {
- switch (action) {
- case Intent.ACTION_HEADSET_PLUG:
- int state = intent.getIntExtra("state", -1);
- switch (state) {
- case 0:
- Log.d(TAG, "Headset unplugged");
- pause();
- break;
- case 1:
- Log.d(TAG, "Headset plugged");
- play();
- break;
- }
- break;
+ if (Intent.ACTION_HEADSET_PLUG.equals(action)) {
+ int state = intent.getIntExtra("state", -1);
+ switch (state) {
+ case 0:
+ Log.d(TAG, "Headset unplugged");
+ pause();
+ break;
+ case 1:
+ Log.d(TAG, "Headset plugged");
+ play();
+ break;
+ }
}
}
}
@@ -352,7 +350,10 @@ public class MusicService extends Service implements SharedPreferences.OnSharedP
PendingIntent mediaButtonReceiverPendingIntent = PendingIntent.getBroadcast(getApplicationContext(), 0, mediaButtonIntent, 0);
- mediaSession = new MediaSessionCompat(this, "RetroMusicPlayer", mediaButtonReceiverComponentName, mediaButtonReceiverPendingIntent);
+ mediaSession = new MediaSessionCompat(this,
+ "RetroMusicPlayer",
+ mediaButtonReceiverComponentName,
+ mediaButtonReceiverPendingIntent);
mediaSession.setCallback(new MediaSessionCompat.Callback() {
@Override
public void onPlay() {
@@ -390,8 +391,9 @@ public class MusicService extends Service implements SharedPreferences.OnSharedP
}
});
- mediaSession.setFlags(MediaSession.FLAG_HANDLES_TRANSPORT_CONTROLS
- | MediaSession.FLAG_HANDLES_MEDIA_BUTTONS);
+ mediaSession.setFlags(MediaSessionCompat.FLAG_HANDLES_MEDIA_BUTTONS
+ | MediaSessionCompat.FLAG_HANDLES_TRANSPORT_CONTROLS
+ );
mediaSession.setMediaButtonReceiver(mediaButtonReceiverPendingIntent);
}
@@ -417,31 +419,7 @@ public class MusicService extends Service implements SharedPreferences.OnSharedP
play();
break;
case ACTION_PLAY_PLAYLIST:
- Playlist playlist = intent.getParcelableExtra(INTENT_EXTRA_PLAYLIST);
- int shuffleMode = intent.getIntExtra(INTENT_EXTRA_SHUFFLE_MODE, getShuffleMode());
- if (playlist != null) {
- ArrayList playlistSongs;
- if (playlist instanceof AbsCustomPlaylist) {
- playlistSongs = ((AbsCustomPlaylist) playlist).getSongs(getApplicationContext()).blockingFirst();
- } else {
- //noinspection unchecked
- playlistSongs = PlaylistSongsLoader.INSTANCE.getPlaylistSongList(getApplicationContext(), playlist.id).blockingFirst();
- }
- if (!playlistSongs.isEmpty()) {
- if (shuffleMode == SHUFFLE_MODE_SHUFFLE) {
- int startPosition;
- startPosition = new Random().nextInt(playlistSongs.size());
- openQueue(playlistSongs, startPosition, true);
- setShuffleMode(shuffleMode);
- } else {
- openQueue(playlistSongs, 0, true);
- }
- } else {
- Toast.makeText(getApplicationContext(), R.string.playlist_is_empty, Toast.LENGTH_LONG).show();
- }
- } else {
- Toast.makeText(getApplicationContext(), R.string.playlist_is_empty, Toast.LENGTH_LONG).show();
- }
+ playFromPlaylist(intent);
break;
case ACTION_REWIND:
back(true);
@@ -464,6 +442,45 @@ public class MusicService extends Service implements SharedPreferences.OnSharedP
return START_STICKY;
}
+ private void playFromPlaylist(Intent intent) {
+ Playlist playlist = intent.getParcelableExtra(INTENT_EXTRA_PLAYLIST);
+ int shuffleMode = intent.getIntExtra(INTENT_EXTRA_SHUFFLE_MODE, getShuffleMode());
+
+ if (playlist != null) {
+ if (playlist instanceof AbsCustomPlaylist) {
+ ((AbsCustomPlaylist) playlist).getSongs(getApplicationContext())
+ .subscribeOn(Schedulers.io())
+ .subscribe(songs -> {
+ playSongs(shuffleMode, songs);
+ }, throwable -> {
+ });
+ } else {
+ PlaylistSongsLoader.INSTANCE.getPlaylistSongList(getApplicationContext(), playlist.id)
+ .subscribeOn(Schedulers.io())
+ .subscribe(songs -> {
+ playSongs(shuffleMode, songs);
+ }, throwable -> {
+ });
+ }
+ } else {
+ Toast.makeText(getApplicationContext(), R.string.playlist_is_empty, Toast.LENGTH_LONG).show();
+ }
+ }
+
+ private void playSongs(int shuffleMode, ArrayList playlistSongs) {
+ if (!playlistSongs.isEmpty()) {
+ if (shuffleMode == SHUFFLE_MODE_SHUFFLE) {
+ int startPosition;
+ startPosition = new Random().nextInt(playlistSongs.size());
+ openQueue(playlistSongs, startPosition, true);
+ setShuffleMode(shuffleMode);
+ } else {
+ openQueue(playlistSongs, 0, true);
+ }
+ } else {
+ Toast.makeText(getApplicationContext(), R.string.playlist_is_empty, Toast.LENGTH_LONG).show();
+ }
+ }
@Override
public void onDestroy() {
diff --git a/app/src/main/java/code/name/monkey/retromusic/service/notification/PlayingNotificationImpl.kt b/app/src/main/java/code/name/monkey/retromusic/service/notification/PlayingNotificationImpl.kt
index e6d612f8..764c255d 100644
--- a/app/src/main/java/code/name/monkey/retromusic/service/notification/PlayingNotificationImpl.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/service/notification/PlayingNotificationImpl.kt
@@ -33,13 +33,13 @@ import code.name.monkey.retromusic.Constants.ACTION_REWIND
import code.name.monkey.retromusic.Constants.ACTION_SKIP
import code.name.monkey.retromusic.Constants.ACTION_TOGGLE_PAUSE
import code.name.monkey.retromusic.R
+import code.name.monkey.retromusic.activities.MainActivity
import code.name.monkey.retromusic.appwidgets.base.BaseAppWidget.Companion.createBitmap
import code.name.monkey.retromusic.glide.GlideApp
import code.name.monkey.retromusic.glide.RetroGlideExtension
import code.name.monkey.retromusic.glide.RetroSimpleTarget
import code.name.monkey.retromusic.glide.palette.BitmapPaletteWrapper
import code.name.monkey.retromusic.service.MusicService
-import code.name.monkey.retromusic.activities.MainActivity
import code.name.monkey.retromusic.util.PreferenceUtil
import code.name.monkey.retromusic.util.RetroColorUtil
import code.name.monkey.retromusic.util.RetroUtil
@@ -89,8 +89,7 @@ class PlayingNotificationImpl : PlayingNotification() {
.getActivity(service, 0, action, PendingIntent.FLAG_UPDATE_CURRENT)
val deleteIntent = buildPendingIntent(service, ACTION_QUIT, null)
- val notification = NotificationCompat.Builder(service,
- PlayingNotification.NOTIFICATION_CHANNEL_ID)
+ val notification = NotificationCompat.Builder(service, NOTIFICATION_CHANNEL_ID)
.setSmallIcon(R.drawable.ic_notification)
.setContentIntent(clickIntent)
.setDeleteIntent(deleteIntent)
diff --git a/app/src/main/java/code/name/monkey/retromusic/service/notification/PlayingNotificationOreo.kt b/app/src/main/java/code/name/monkey/retromusic/service/notification/PlayingNotificationOreo.kt
index d57f5b44..15c24a5b 100644
--- a/app/src/main/java/code/name/monkey/retromusic/service/notification/PlayingNotificationOreo.kt
+++ b/app/src/main/java/code/name/monkey/retromusic/service/notification/PlayingNotificationOreo.kt
@@ -30,13 +30,13 @@ import code.name.monkey.retromusic.Constants.ACTION_REWIND
import code.name.monkey.retromusic.Constants.ACTION_SKIP
import code.name.monkey.retromusic.Constants.ACTION_TOGGLE_PAUSE
import code.name.monkey.retromusic.R
+import code.name.monkey.retromusic.activities.MainActivity
import code.name.monkey.retromusic.glide.GlideApp
import code.name.monkey.retromusic.glide.RetroGlideExtension
import code.name.monkey.retromusic.glide.RetroSimpleTarget
import code.name.monkey.retromusic.glide.palette.BitmapPaletteWrapper
import code.name.monkey.retromusic.model.Song
import code.name.monkey.retromusic.service.MusicService
-import code.name.monkey.retromusic.activities.MainActivity
import code.name.monkey.retromusic.util.PreferenceUtil
import code.name.monkey.retromusic.util.RetroUtil
import code.name.monkey.retromusic.util.RetroUtil.createBitmap
@@ -87,8 +87,7 @@ class PlayingNotificationOreo : PlayingNotification() {
.getActivity(service, 0, action, PendingIntent.FLAG_UPDATE_CURRENT)
val deleteIntent = buildPendingIntent(service, ACTION_QUIT, null)
- val builder = NotificationCompat.Builder(service,
- PlayingNotification.NOTIFICATION_CHANNEL_ID)
+ val builder = NotificationCompat.Builder(service, NOTIFICATION_CHANNEL_ID)
.setSmallIcon(R.drawable.ic_notification)
.setContentIntent(clickIntent)
.setDeleteIntent(deleteIntent)
diff --git a/app/src/main/java/code/name/monkey/retromusic/util/ImageUtil.java b/app/src/main/java/code/name/monkey/retromusic/util/ImageUtil.java
index eccda10b..1d1dfb3e 100644
--- a/app/src/main/java/code/name/monkey/retromusic/util/ImageUtil.java
+++ b/app/src/main/java/code/name/monkey/retromusic/util/ImageUtil.java
@@ -220,7 +220,8 @@ public class ImageUtil {
return inSampleSize;
}
- public static Bitmap getResizedBitmap(Bitmap image, int maxSize) {
+ @NonNull
+ public static Bitmap getResizedBitmap(@NonNull Bitmap image, int maxSize) {
int width = image.getWidth();
int height = image.getHeight();
diff --git a/app/src/main/java/code/name/monkey/retromusic/util/PreferenceUtil.java b/app/src/main/java/code/name/monkey/retromusic/util/PreferenceUtil.java
index 8548a049..591e0204 100644
--- a/app/src/main/java/code/name/monkey/retromusic/util/PreferenceUtil.java
+++ b/app/src/main/java/code/name/monkey/retromusic/util/PreferenceUtil.java
@@ -147,8 +147,6 @@ public final class PreferenceUtil {
return R.style.Theme_RetroMusic_Light;
case "color":
return R.style.Theme_RetroMusic_Color;
- case "acolor":
- return R.style.Theme_RetroMusic_Black;
case "black":
return R.style.Theme_RetroMusic_Black;
case "daynight":
@@ -306,6 +304,10 @@ public final class PreferenceUtil {
return mPreferences.getBoolean(COLORED_NOTIFICATION, true);
}
+ public final void setColoredNotification(boolean b) {
+ mPreferences.edit().putBoolean(COLORED_NOTIFICATION, b).apply();
+ }
+
public final boolean classicNotification() {
return mPreferences.getBoolean(CLASSIC_NOTIFICATION, false);
}
diff --git a/app/src/main/java/code/name/monkey/retromusic/util/RetroColorUtil.java b/app/src/main/java/code/name/monkey/retromusic/util/RetroColorUtil.java
index b961ae67..220b4fc3 100644
--- a/app/src/main/java/code/name/monkey/retromusic/util/RetroColorUtil.java
+++ b/app/src/main/java/code/name/monkey/retromusic/util/RetroColorUtil.java
@@ -37,7 +37,7 @@ import code.name.monkey.retromusic.R;
public class RetroColorUtil {
public static int toolbarColor(@NonNull Context context) {
int color = ThemeStore.Companion.primaryColor(context);
- if (ATHUtil.INSTANCE.isWindowBackgroundDark(context)) {
+ if (ATHUtil.INSTANCE.isWindowBackgroundDark(context) && PreferenceUtil.getInstance().getGeneralTheme() != R.style.Theme_RetroMusic_Color) {
return ATHUtil.INSTANCE.resolveColor(context, R.attr.cardBackgroundColor);
} else {
return color;
diff --git a/app/src/main/java/code/name/monkey/retromusic/views/RetroChip.kt b/app/src/main/java/code/name/monkey/retromusic/views/RetroChip.kt
new file mode 100644
index 00000000..5b92fb71
--- /dev/null
+++ b/app/src/main/java/code/name/monkey/retromusic/views/RetroChip.kt
@@ -0,0 +1,36 @@
+/*
+ * Copyright (c) 2019 Hemanth Savarala.
+ *
+ * Licensed under the GNU General Public License v3
+ *
+ * This is free software: you can redistribute it and/or modify it under
+ * the terms of the GNU General Public License as published by
+ * the Free Software Foundation either version 3 of the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
+ * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+ * See the GNU General Public License for more details.
+ */
+
+package code.name.monkey.retromusic.views
+
+import android.content.Context
+import android.content.res.ColorStateList
+import android.util.AttributeSet
+import code.name.monkey.appthemehelper.ThemeStore
+import code.name.monkey.appthemehelper.util.ATHUtil
+import code.name.monkey.retromusic.R
+import com.google.android.material.chip.Chip
+
+class RetroChip @JvmOverloads constructor(
+ context: Context, attrs: AttributeSet? = null, defStyleAttr: Int = 0) :
+ Chip(context, attrs, defStyleAttr) {
+ init {
+ chipBackgroundColor = ColorStateList.valueOf(ThemeStore.primaryColor(context))
+ val iconColor = ATHUtil.resolveColor(context, R.attr.iconColor)
+ val dividerColor = ATHUtil.resolveColor(context, R.attr.dividerColor)
+ chipIcon?.setTintList(ColorStateList.valueOf(iconColor))
+ setTextColor(iconColor)
+ chipStrokeColor = ColorStateList.valueOf(dividerColor)
+ }
+}
diff --git a/app/src/main/res/layout-land/activity_album.xml b/app/src/main/res/layout-land/activity_album.xml
index b675249d..7a0cd264 100644
--- a/app/src/main/res/layout-land/activity_album.xml
+++ b/app/src/main/res/layout-land/activity_album.xml
@@ -30,70 +30,77 @@
-
+ app:cardCornerRadius="16dp"
+ app:cardElevation="0dp">
-
-
+ android:orientation="vertical">
+ android:gravity="center_vertical"
+ android:orientation="horizontal">
-
+
+
+ android:layout_gravity="bottom"
+ android:layout_weight="1"
+ android:orientation="vertical"
+ android:padding="16dp">
-
+
+
+
+
+
+
-
-
-
+
diff --git a/app/src/main/res/layout-land/activity_artist_details.xml b/app/src/main/res/layout-land/activity_artist_details.xml
index 3f6d44be..c1fec3fe 100644
--- a/app/src/main/res/layout-land/activity_artist_details.xml
+++ b/app/src/main/res/layout-land/activity_artist_details.xml
@@ -1,5 +1,6 @@
-
+ app:cardCornerRadius="16dp"
+ app:cardElevation="0dp">
+ android:orientation="vertical">
-
+ android:orientation="vertical"
+ android:padding="16dp">
-
+
+
+
+
+
+
-
+
+
-
-
-
-
+
diff --git a/app/src/main/res/layout-land/fragment_blur.xml b/app/src/main/res/layout-land/fragment_blur.xml
index 3dea59ce..25b1d4f4 100644
--- a/app/src/main/res/layout-land/fragment_blur.xml
+++ b/app/src/main/res/layout-land/fragment_blur.xml
@@ -84,8 +84,8 @@
android:id="@+id/playerToolbar"
style="@style/Toolbar"
android:layout_height="48dp"
- android:navigationIcon="@drawable/ic_close_white_24dp"
- app:navigationIcon="@drawable/ic_close_white_24dp" />
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp" />
diff --git a/app/src/main/res/layout-land/fragment_card_blur_player.xml b/app/src/main/res/layout-land/fragment_card_blur_player.xml
index 510c503f..5104eba6 100644
--- a/app/src/main/res/layout-land/fragment_card_blur_player.xml
+++ b/app/src/main/res/layout-land/fragment_card_blur_player.xml
@@ -50,7 +50,7 @@
app:contentInsetLeft="0dp"
app:contentInsetStart="0dp"
app:contentInsetStartWithNavigation="0dp"
- app:navigationIcon="@drawable/ic_keyboard_backspace_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
app:subtitleTextAppearance="@style/TextAppearance.AppCompat.Caption"
app:titleMargin="0dp"
app:titleMarginStart="0dp"
diff --git a/app/src/main/res/layout-land/fragment_classic_player.xml b/app/src/main/res/layout-land/fragment_classic_player.xml
index bc90d71c..ed62cba9 100644
--- a/app/src/main/res/layout-land/fragment_classic_player.xml
+++ b/app/src/main/res/layout-land/fragment_classic_player.xml
@@ -18,7 +18,9 @@
+ android:background="@android:color/transparent"
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp" />
+ app:cardUseCompatPadding="false"
+ sothree:cardCornerRadius="12dp">
@@ -119,8 +119,8 @@
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp" />
diff --git a/app/src/main/res/layout-land/fragment_flat_player.xml b/app/src/main/res/layout-land/fragment_flat_player.xml
index 0f7d0a88..fb90a778 100644
--- a/app/src/main/res/layout-land/fragment_flat_player.xml
+++ b/app/src/main/res/layout-land/fragment_flat_player.xml
@@ -63,8 +63,8 @@
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp" />
+ app:layout_scrollFlags="scroll|enterAlways"
+ app:strokeColor="?dividerColor"
+ app:strokeWidth="1dp">
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp" />
diff --git a/app/src/main/res/layout-land/fragment_plain_player.xml b/app/src/main/res/layout-land/fragment_plain_player.xml
index de85301e..29e32b70 100644
--- a/app/src/main/res/layout-land/fragment_plain_player.xml
+++ b/app/src/main/res/layout-land/fragment_plain_player.xml
@@ -105,8 +105,8 @@
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp" />
diff --git a/app/src/main/res/layout-land/fragment_player.xml b/app/src/main/res/layout-land/fragment_player.xml
index ee835e88..89a86a80 100755
--- a/app/src/main/res/layout-land/fragment_player.xml
+++ b/app/src/main/res/layout-land/fragment_player.xml
@@ -12,10 +12,6 @@
android:layout_width="match_parent"
android:layout_height="match_parent" />
-
@@ -67,8 +63,8 @@
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp" />
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp" />
diff --git a/app/src/main/res/layout-xlarge-land/activity_album.xml b/app/src/main/res/layout-xlarge-land/activity_album.xml
index 43dbcaa9..bf0fd9e2 100644
--- a/app/src/main/res/layout-xlarge-land/activity_album.xml
+++ b/app/src/main/res/layout-xlarge-land/activity_album.xml
@@ -41,7 +41,6 @@
-
+ app:cardCornerRadius="16dp"
+ app:cardElevation="0dp">
-
-
-
-
-
-
-
-
+ android:orientation="vertical">
+ android:orientation="horizontal">
-
+
+
+
+
+
+
+
+
+ android:layout_weight="1"
+ android:orientation="vertical"
+ android:padding="16dp">
-
+
+
+
+
+
+
-
-
-
-
+
-
-
+ android:layout_height="wrap_content"
+ app:cardCornerRadius="16dp"
+ app:cardElevation="0dp">
+ android:layout_height="match_parent"
+ android:orientation="vertical">
-
+ android:orientation="vertical"
+ android:padding="24dp">
-
+
+
+
+
+
+
+
-
-
-
-
+
diff --git a/app/src/main/res/layout-xlarge-land/fragment_banner_home.xml b/app/src/main/res/layout-xlarge-land/fragment_banner_home.xml
index 486b4c97..89d6a690 100644
--- a/app/src/main/res/layout-xlarge-land/fragment_banner_home.xml
+++ b/app/src/main/res/layout-xlarge-land/fragment_banner_home.xml
@@ -30,7 +30,7 @@
diff --git a/app/src/main/res/layout-xlarge-land/fragment_blur.xml b/app/src/main/res/layout-xlarge-land/fragment_blur.xml
index 8883e93a..d1e6a8ef 100644
--- a/app/src/main/res/layout-xlarge-land/fragment_blur.xml
+++ b/app/src/main/res/layout-xlarge-land/fragment_blur.xml
@@ -73,10 +73,10 @@
android:id="@+id/playerToolbar"
style="@style/Toolbar"
android:layout_height="48dp"
- android:navigationIcon="@drawable/ic_close_white_24dp"
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
- app:navigationIcon="@drawable/ic_close_white_24dp" />
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp" />
\ No newline at end of file
diff --git a/app/src/main/res/layout-xlarge-land/fragment_home.xml b/app/src/main/res/layout-xlarge-land/fragment_home.xml
index 0ddbc4f0..76dc99dc 100644
--- a/app/src/main/res/layout-xlarge-land/fragment_home.xml
+++ b/app/src/main/res/layout-xlarge-land/fragment_home.xml
@@ -31,10 +31,14 @@
android:id="@+id/toolbarContainer"
android:layout_width="match_parent"
android:layout_height="wrap_content"
+ android:layout_marginStart="8dp"
+ android:layout_marginEnd="8dp"
app:cardCornerRadius="8dp"
- app:cardElevation="6dp"
+ app:cardElevation="0dp"
app:cardUseCompatPadding="true"
- app:layout_scrollFlags="scroll|enterAlways">
+ app:layout_scrollFlags="scroll|enterAlways"
+ app:strokeColor="?dividerColor"
+ app:strokeWidth="1dp">
-
-
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp" />
diff --git a/app/src/main/res/layout-xlarge/abs_playlists.xml b/app/src/main/res/layout-xlarge/abs_playlists.xml
index ddd3129f..1a499e09 100644
--- a/app/src/main/res/layout-xlarge/abs_playlists.xml
+++ b/app/src/main/res/layout-xlarge/abs_playlists.xml
@@ -13,10 +13,7 @@
android:layout_gravity="center_vertical"
android:gravity="center_vertical"
android:orientation="horizontal"
- android:paddingStart="24dp"
- android:paddingTop="10dp"
- android:paddingEnd="24dp"
- android:paddingBottom="10dp">
+ android:padding="24dp">
-
+ android:layout_height="wrap_content"
+ app:cardCornerRadius="16dp"
+ app:cardElevation="0dp">
-
-
-
-
-
-
-
-
+ android:layout_height="match_parent"
+ android:orientation="vertical">
+ android:baselineAligned="false"
+ android:orientation="horizontal">
-
+
+
+
+
+
+
+
+
+ android:layout_weight="1"
+ android:orientation="vertical"
+ android:paddingStart="16dp"
+ android:paddingEnd="16dp">
-
+
+
+
+
+
+
-
-
-
-
+
-
-
+ android:layout_height="wrap_content"
+ app:cardCornerRadius="16dp"
+ app:cardElevation="0dp">
+ tools:background="@color/md_red_500">
-
+ android:orientation="vertical"
+ android:padding="12dp">
-
+
+
+
+
+
+
+
+
-
-
-
-
-
+
diff --git a/app/src/main/res/layout-xlarge/activity_user_info.xml b/app/src/main/res/layout-xlarge/activity_user_info.xml
index 5655da6e..80bda0ba 100644
--- a/app/src/main/res/layout-xlarge/activity_user_info.xml
+++ b/app/src/main/res/layout-xlarge/activity_user_info.xml
@@ -98,12 +98,12 @@
@@ -119,12 +119,12 @@
@@ -135,7 +135,8 @@
android:background="@null"
android:hint="@string/bio"
android:inputType="textPersonName|textCapWords|text"
- android:textAppearance="@style/TextAppearance.AppCompat.Subhead" />
+ android:textAppearance="@style/TextAppearance.AppCompat.Subhead"
+ android:visibility="gone" />
@@ -147,8 +148,8 @@
android:layout_gravity="bottom"
android:layout_margin="16dp"
android:gravity="center"
- app:iconGravity="textStart"
android:padding="16dp"
android:text="@string/save"
- app:icon="@drawable/ic_save_white_24dp" />
+ app:icon="@drawable/ic_save_white_24dp"
+ app:iconGravity="textStart" />
\ No newline at end of file
diff --git a/app/src/main/res/layout-xlarge/fragment_banner_home.xml b/app/src/main/res/layout-xlarge/fragment_banner_home.xml
index ec497cca..5e194f47 100644
--- a/app/src/main/res/layout-xlarge/fragment_banner_home.xml
+++ b/app/src/main/res/layout-xlarge/fragment_banner_home.xml
@@ -30,7 +30,7 @@
diff --git a/app/src/main/res/layout-xlarge/fragment_blur.xml b/app/src/main/res/layout-xlarge/fragment_blur.xml
index 83fed952..30c1da40 100644
--- a/app/src/main/res/layout-xlarge/fragment_blur.xml
+++ b/app/src/main/res/layout-xlarge/fragment_blur.xml
@@ -81,8 +81,8 @@
android:id="@+id/playerToolbar"
style="@style/Toolbar"
android:layout_height="48dp"
- android:navigationIcon="@drawable/ic_close_white_24dp"
- app:navigationIcon="@drawable/ic_close_white_24dp" />
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp" />
diff --git a/app/src/main/res/layout-xlarge/fragment_home.xml b/app/src/main/res/layout-xlarge/fragment_home.xml
index 38b52649..0368f661 100644
--- a/app/src/main/res/layout-xlarge/fragment_home.xml
+++ b/app/src/main/res/layout-xlarge/fragment_home.xml
@@ -32,16 +32,20 @@
android:id="@+id/toolbarContainer"
android:layout_width="match_parent"
android:layout_height="wrap_content"
+ android:layout_marginStart="64dp"
+ android:layout_marginEnd="64dp"
app:cardCornerRadius="8dp"
- app:cardElevation="6dp"
+ app:cardElevation="0dp"
app:cardUseCompatPadding="true"
- app:layout_scrollFlags="scroll|enterAlways">
+ app:layout_scrollFlags="scroll|enterAlways"
+ app:strokeColor="?dividerColor"
+ app:strokeWidth="1dp">
diff --git a/app/src/main/res/layout-xlarge/fragment_player.xml b/app/src/main/res/layout-xlarge/fragment_player.xml
index 1d6d7a61..c919d1ef 100644
--- a/app/src/main/res/layout-xlarge/fragment_player.xml
+++ b/app/src/main/res/layout-xlarge/fragment_player.xml
@@ -11,10 +11,7 @@
android:id="@+id/colorGradientBackground"
android:layout_width="match_parent"
android:layout_height="match_parent" />
-
+
+
+
+
+
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp" />
diff --git a/app/src/main/res/layout/activity_album.xml b/app/src/main/res/layout/activity_album.xml
index d4749c39..da066f7d 100755
--- a/app/src/main/res/layout/activity_album.xml
+++ b/app/src/main/res/layout/activity_album.xml
@@ -46,69 +46,75 @@
-
+ app:cardCornerRadius="16dp"
+ app:cardElevation="0dp">
-
-
+ android:orientation="vertical">
+ android:orientation="horizontal"
+ android:padding="12dp">
-
+
+
+ android:layout_weight="1"
+ android:orientation="vertical"
+ android:paddingStart="16dp"
+ android:paddingEnd="0dp">
-
+
+
+
+
+
+
+
-
-
-
-
+
\ No newline at end of file
diff --git a/app/src/main/res/layout/activity_artist_details.xml b/app/src/main/res/layout/activity_artist_details.xml
index 98597a92..8a8c57a4 100755
--- a/app/src/main/res/layout/activity_artist_details.xml
+++ b/app/src/main/res/layout/activity_artist_details.xml
@@ -47,54 +47,60 @@
-
+ app:cardCornerRadius="16dp"
+ app:cardElevation="0dp">
+ android:orientation="vertical">
-
+ android:orientation="vertical"
+ android:padding="16dp">
+
+
+
+
+
+
+
+
-
-
-
-
-
-
+
diff --git a/app/src/main/res/layout/activity_search.xml b/app/src/main/res/layout/activity_search.xml
index cb0e1a8a..7d2b0f07 100755
--- a/app/src/main/res/layout/activity_search.xml
+++ b/app/src/main/res/layout/activity_search.xml
@@ -19,9 +19,14 @@
android:id="@+id/searchContainer"
android:layout_width="match_parent"
android:layout_height="wrap_content"
+ android:layout_marginStart="8dp"
+ android:layout_marginEnd="8dp"
app:cardCornerRadius="8dp"
- app:cardElevation="6dp"
- app:cardUseCompatPadding="true">
+ app:cardElevation="0dp"
+ app:cardUseCompatPadding="true"
+ app:layout_scrollFlags="scroll|enterAlways"
+ app:strokeColor="?dividerColor"
+ app:strokeWidth="1dp">
diff --git a/app/src/main/res/layout/activity_user_info.xml b/app/src/main/res/layout/activity_user_info.xml
index 708ed465..6e2e4121 100644
--- a/app/src/main/res/layout/activity_user_info.xml
+++ b/app/src/main/res/layout/activity_user_info.xml
@@ -35,7 +35,9 @@
diff --git a/app/src/main/res/layout/fragment_banner_home.xml b/app/src/main/res/layout/fragment_banner_home.xml
index 136bca69..0a554f34 100644
--- a/app/src/main/res/layout/fragment_banner_home.xml
+++ b/app/src/main/res/layout/fragment_banner_home.xml
@@ -58,6 +58,8 @@
android:layout_height="wrap_content"
app:cardCornerRadius="8dp"
app:cardElevation="6dp"
+ android:layout_marginEnd="8dp"
+ android:layout_marginStart="8dp"
app:cardUseCompatPadding="true"
app:layout_scrollFlags="scroll|enterAlways">
diff --git a/app/src/main/res/layout/fragment_blur.xml b/app/src/main/res/layout/fragment_blur.xml
index 4f318abf..2a4f05a9 100644
--- a/app/src/main/res/layout/fragment_blur.xml
+++ b/app/src/main/res/layout/fragment_blur.xml
@@ -75,8 +75,8 @@
android:id="@+id/playerToolbar"
style="@style/Toolbar"
android:layout_height="48dp"
- android:navigationIcon="@drawable/ic_close_white_24dp"
- app:navigationIcon="@drawable/ic_close_white_24dp" />
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp" />
diff --git a/app/src/main/res/layout/fragment_card_blur_player.xml b/app/src/main/res/layout/fragment_card_blur_player.xml
index 37f33a7c..3ba425f4 100644
--- a/app/src/main/res/layout/fragment_card_blur_player.xml
+++ b/app/src/main/res/layout/fragment_card_blur_player.xml
@@ -54,7 +54,7 @@
app:contentInsetLeft="0dp"
app:contentInsetStart="0dp"
app:contentInsetStartWithNavigation="0dp"
- app:navigationIcon="@drawable/ic_keyboard_backspace_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
app:subtitleTextAppearance="@style/TextAppearance.AppCompat.Caption"
app:titleMargin="0dp"
app:titleMarginStart="0dp"
diff --git a/app/src/main/res/layout/fragment_classic_player.xml b/app/src/main/res/layout/fragment_classic_player.xml
index f044916e..e1fda879 100644
--- a/app/src/main/res/layout/fragment_classic_player.xml
+++ b/app/src/main/res/layout/fragment_classic_player.xml
@@ -76,7 +76,9 @@
+ android:background="@android:color/transparent"
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp" />
@@ -100,9 +102,9 @@
sothree:cardCornerRadius="12dp">
+ android:layout_height="wrap_content"
+ android:background="?cardBackgroundColor">
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp" />
diff --git a/app/src/main/res/layout/fragment_color_player_playback_controls.xml b/app/src/main/res/layout/fragment_color_player_playback_controls.xml
index 74aabe17..2a2ba8d3 100644
--- a/app/src/main/res/layout/fragment_color_player_playback_controls.xml
+++ b/app/src/main/res/layout/fragment_color_player_playback_controls.xml
@@ -43,16 +43,13 @@
android:textSize="12sp"
tools:ignore="RtlHardcoded,RtlSymmetry" />
-
diff --git a/app/src/main/res/layout/fragment_fit.xml b/app/src/main/res/layout/fragment_fit.xml
index 0c40f173..ee08b364 100644
--- a/app/src/main/res/layout/fragment_fit.xml
+++ b/app/src/main/res/layout/fragment_fit.xml
@@ -48,8 +48,8 @@
android:id="@+id/playerToolbar"
style="@style/Toolbar"
android:layout_gravity="bottom"
- android:navigationIcon="@drawable/ic_close_white_24dp"
- app:navigationIcon="@drawable/ic_close_white_24dp" />
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp" />
diff --git a/app/src/main/res/layout/fragment_flat_player.xml b/app/src/main/res/layout/fragment_flat_player.xml
index c1027662..9ee1a7ed 100644
--- a/app/src/main/res/layout/fragment_flat_player.xml
+++ b/app/src/main/res/layout/fragment_flat_player.xml
@@ -40,8 +40,8 @@
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp" />
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp">
diff --git a/app/src/main/res/layout/fragment_library.xml b/app/src/main/res/layout/fragment_library.xml
index fe5f533e..536c19ac 100644
--- a/app/src/main/res/layout/fragment_library.xml
+++ b/app/src/main/res/layout/fragment_library.xml
@@ -34,7 +34,10 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:cardCornerRadius="8dp"
- app:strokeColor="@color/black_color"
+ app:cardElevation="0dp"
+ android:layout_marginEnd="8dp"
+ android:layout_marginStart="8dp"
+ app:strokeColor="?dividerColor"
app:cardUseCompatPadding="true"
app:layout_scrollFlags="scroll|enterAlways"
app:strokeWidth="1dp">
diff --git a/app/src/main/res/layout/fragment_main_activity_recycler_view.xml b/app/src/main/res/layout/fragment_main_activity_recycler_view.xml
index 5e389b02..11ce06a0 100644
--- a/app/src/main/res/layout/fragment_main_activity_recycler_view.xml
+++ b/app/src/main/res/layout/fragment_main_activity_recycler_view.xml
@@ -26,7 +26,7 @@
+ app:srcCompat="@drawable/ic_music_note_off_white_24dp" />
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp" />
diff --git a/app/src/main/res/layout/fragment_plain_player.xml b/app/src/main/res/layout/fragment_plain_player.xml
index ea7253fb..9725f6d3 100644
--- a/app/src/main/res/layout/fragment_plain_player.xml
+++ b/app/src/main/res/layout/fragment_plain_player.xml
@@ -92,8 +92,8 @@
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp" />
diff --git a/app/src/main/res/layout/fragment_player.xml b/app/src/main/res/layout/fragment_player.xml
index 9d992988..bebbaf54 100644
--- a/app/src/main/res/layout/fragment_player.xml
+++ b/app/src/main/res/layout/fragment_player.xml
@@ -12,10 +12,6 @@
android:layout_width="match_parent"
android:layout_height="match_parent" />
-
@@ -72,8 +68,8 @@
android:id="@+id/playerToolbar"
style="@style/Toolbar"
android:layout_gravity="bottom"
- android:navigationIcon="@drawable/ic_close_white_24dp"
- app:navigationIcon="@drawable/ic_close_white_24dp" />
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp" />
diff --git a/app/src/main/res/layout/fragment_simple_player.xml b/app/src/main/res/layout/fragment_simple_player.xml
index ee29910f..8751abfb 100644
--- a/app/src/main/res/layout/fragment_simple_player.xml
+++ b/app/src/main/res/layout/fragment_simple_player.xml
@@ -27,7 +27,6 @@
-
@@ -61,8 +60,8 @@
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp" />
diff --git a/app/src/main/res/layout/fragment_tiny_player.xml b/app/src/main/res/layout/fragment_tiny_player.xml
index 13d965e7..0cb2dc05 100644
--- a/app/src/main/res/layout/fragment_tiny_player.xml
+++ b/app/src/main/res/layout/fragment_tiny_player.xml
@@ -101,7 +101,8 @@
+ android:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp"
+ app:navigationIcon="@drawable/ic_keyboard_arrow_down_black_24dp" />
diff --git a/app/src/main/res/layout/fragment_volume.xml b/app/src/main/res/layout/fragment_volume.xml
index 658218d5..2a5e2859 100755
--- a/app/src/main/res/layout/fragment_volume.xml
+++ b/app/src/main/res/layout/fragment_volume.xml
@@ -1,6 +1,7 @@
+ tools:progress="20" />
+ app:srcCompat="@drawable/ic_play_arrow_white_64dp" />
\ No newline at end of file
diff --git a/app/src/main/res/layout/item_list_quick_actions.xml b/app/src/main/res/layout/item_list_quick_actions.xml
index 354ef1a1..bd1a81b2 100644
--- a/app/src/main/res/layout/item_list_quick_actions.xml
+++ b/app/src/main/res/layout/item_list_quick_actions.xml
@@ -26,7 +26,7 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="4dp"
- android:layout_marginEnd="8dp"
+ android:layout_marginEnd="4dp"
android:layout_weight="1"
android:padding="10dp"
android:text="@string/action_play_all"
@@ -41,7 +41,7 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="4dp"
- android:layout_marginEnd="8dp"
+ android:layout_marginEnd="4dp"
android:layout_weight="1"
android:padding="10dp"
android:text="@string/shuffle"
diff --git a/app/src/main/res/layout/metal_section_recycler_view.xml b/app/src/main/res/layout/metal_section_recycler_view.xml
index af2d7e36..e4340502 100644
--- a/app/src/main/res/layout/metal_section_recycler_view.xml
+++ b/app/src/main/res/layout/metal_section_recycler_view.xml
@@ -1,37 +1,25 @@
-
-
-
-
-
-
-
+ android:fontFamily="@font/circular"
+ android:textColor="?android:textColorSecondary"
+ app:chipIconTint="?iconColor"
+ app:chipStrokeColor="?dividerColor"
+ app:chipStrokeWidth="1dp"
+ app:iconStartPadding="8dp"
+ tools:chipIcon="@drawable/ic_person_white_24dp"
+ tools:text="@string/for_you" />
-
-
-
-
-
-
-
+ android:fontFamily="@font/circular"
+ app:chipIconTint="?iconColor"
+ app:chipStrokeColor="?dividerColor"
+ app:chipStrokeWidth="1dp"
+ app:iconStartPadding="8dp"
+ tools:chipIcon="@drawable/ic_person_white_24dp"
+ tools:text="@string/for_you" />
+ 扫描到的歌词
+ 歌曲
+ 全部播放
+ 搜索您的资料库…
+ 您最近播放过的专辑
+ 您最近听过 TA 们的歌
+ 小专辑
+ 欢迎您,
+ 脱颖专辑
+ 脱颖艺人
+ 黑名单
+ 设置艺人图片
+ 重置艺人图片
强调色
- 主题强调色,默认为蓝绿色。
+ 封面主题
+ 主题强调色,默认为蓝绿。
+ 个人资料
关于
+ 反馈漏洞
+ 使用 GitHub 账号发送反馈
+ 另存为文件
+ 另存为文件
+ 登陆
+ 手动发送
+ 您将会被导向至漏洞追踪器页面
+ 加入我们的 Telegram 群组,与万千用户,以及我们的开发人员一起,解决漏洞,交流讨论,谈天说地
+ 问题
+ 标题
+ 描述
+ 用户名
+ 密码
+ 设备信息
+ 反馈问题
+ 请输入正确的 GitHub 用户名
+ 请输入正确的 GitHub 密码
+ 请输入问题的标题
+ 协助开发
+ 请输入您对问题的描述
+ 正在向 GitHub 提交您的问题…
+ 无法发送您的问题
+ 用户名或密码错误
+ 无效的访问令牌,请联系应用开发者。
+ 未对所选存储库启用问题,请联系应用开发者。
+ 发生了意料之外的问题,请联系应用开发者
+ 翻译
+ 帮助我们使这款播放器以您的语言呈现内容
+ 已经把您的设备信息复制到剪贴板了
添加到收藏夹
添加到播放队列
- 添加到播放列表…
+ 添加到播放列表
清空播放队列
清空播放列表
删除
@@ -37,12 +81,13 @@
"设置"
分享
随机播放全部
- 随机播放播放列表
+ 随机播放列表
睡眠定时器
排序
标签编辑器
自适应
添加
+ 您的帐户数据将仅用于身份验证
添加\n头像
"添加到播放列表"
"已加入播放队列"
@@ -53,48 +98,60 @@
专辑
始终
- 嘿快来瞧瞧这个酷炫的音乐播放器:https://play.google.com/store/apps/details?id=%s
+ 妈耶!这个音乐播放器帅到爆炸!https://play.google.com/store/apps/details?id=%s
@string/last_added
@string/last_added
@string/action_shuffle_all
@string/my_top_tracks
随机播放
- 顶级轨道
- Retro音乐 - 大
+ 畅响天籁
+ Retro Music - 大
Retro Music - 卡片模式
Retro Music - 经典模式
- Retro音乐 - 小
+ Retro Music - 小
歌手
歌手
音频焦点丢失
更改声音设置和均衡器设置
低音增强
简介
- 纯黑
+ 纯粹黑
黑名单
模糊
模糊卡片
屏幕常亮
请注意,启用此功能可能会降低电池续航时间
- 模糊量
- 应用于模糊主题,数量越低加载越快
+ 模糊度
+ 应用于模糊主题,数量越低,加载越快
取消
卡片
- 彩色卡片
+ 彩色卡片式
圆形
+ 背景图
+ 选择一张新背景图
+ 移除当前背景图
+ 选择一张新头像
图片
- 卡片
+ 应用
+ 卡片式
+ 当天
+ 一个月内
+ 一周内
+ 一年内
+ 筛选歌曲时长
投射
更新日志
- 在Telegram频道上维护更新日志
- 透明
+ 在 Telegram 频道上维护更新日志
+ 被列入黑名单的文件夹中的音频,将不会出现在播放器中
+ 清除
清空黑名单
清除播放列表
%1$s \u5417\uff1f\u8bf7\u6ce8\u610f\uff0c\u6b64\u64cd\u4f5c\u4e0d\u53ef\u6062\u590d\uff01]]>
关闭
- 颜色
- 颜色
+ 多彩
+ 自定义
+ 播放器的主色调,默认蓝灰色。使用深色效果更佳。
更多颜色
\u4e0d\u80fd\u521b\u5efa\u64ad\u653e\u5217\u8868
"\u65e0\u6cd5\u4e0b\u8f7d\u5339\u914d\u7684\u4e13\u8f91\u5c01\u9762"
@@ -104,7 +161,7 @@
已创建播放列表 %1$s
开发团队和贡献者
当前通过 %2$s 收听 %1$s
- 浅黑
+ 深空灰
没有歌词
删除播放列表
%1$s 吗?]]>
@@ -113,11 +170,13 @@
%1$s 吗?]]>
%1$s 吗?]]>
已删除 %1$d 首歌曲
- 你想清除黑名单吗?
+ 您想清除黑名单吗?
%1$s 吗?]]>
- 捐赠
- 如果你觉得我的应用好用,你可以在这里捐赠一些资金,你的支持是我开发的动力
- 用以下方式捐赠:
+ 赞助
+ 关注我们的 Pinterest 主页,随时随地了解我们的设计灵感吧!
+ 如果您觉得这款播放器还对你的胃口,欢迎您为这款应用赞助!您的支持,就是我最大的动力!
+ 感觉还不错?5 星好评一下怎么样!或者您也可以把您的想法留在评论里,帮助这款播放器锦上添花!
+ 您可以使用以下方式赞助我们:
从 Last.fm 下载
编辑专辑封面
空空如也
@@ -126,20 +185,21 @@
收藏夹
扁平
文件夹
- 给你的
- 满
+ 专属于您
+ 卡片式全屏幕
+ 全屏幕
更改应用的主题和颜色
界面外观
流派
流派
- 在GitHub上Fork项目
- 加入Google+社区获得帮助或者更新信息
+ 在 GitHub 上 Fork 项目
+ 加入 Google+ 社区获得帮助或者更新信息
历史记录
主页
更改艺术家图片下载设置
- 将歌曲%1$d加入%2$s列表
+ 将歌曲 %1$d 加入 %2$s 列表
Instagram
- 分享你的设置到Instagram
+ 分享您的设置到 Instagram
比特率
格式
文件名
@@ -147,47 +207,89 @@
大小
采样率
长度
- 上次添加
+ 最近添加
来点音乐吧!
- 库
+ 资料库
许可
- 纯白
- 正在罗列所有文件
- 加载产品...
+ 皓月白
+ 正在罗列出所有文件
+ 劳烦您稍等一下…(若始终无法加载,请尝试使用爬墙工具)
歌词
- 材质
+ 质感
我的名字
- 播放最多
+ 我的最爱
从不
- 新播放列表
- 新头像
- %s是新的开始目录
- 无专辑
- 无艺术家
- "先放首曲子,然后再试试"
- 找不到均衡器
+ 新建播放列表
+ %s 是新的开始目录
+ 还没有专辑
+ 还没有艺术家
+ "请先放首曲子,然后再试试"
+ 暂时没有均衡器
无流派
找不到歌词
- 无播放列表
+ 还没有创建播放列表
找不到支付记录
+
无结果
无歌曲
+ 作曲家
+ "音轨 (使用 2 来代表轨道 2,或者使用 3004 来代表 CD3 轨道 4)"
+ 作曲家
+
+ 接下来
+ 分享音频文件
+ 清除播放队列
正常
- 正常歌词
+ 播放队列
+ 一般歌词
+ 发送崩溃日志
正常
- %s在多媒体商店没列出]]>
+ 编辑
+ 添加歌词
+ 将您的歌词粘贴在这里
+ %s 未在 MediaStore 中列出]]>
检索不到任何东西
通知烂
自定义通知栏风格
正在播放
播放队列
- 仅限Wi-Fi
+ 仅限 Wi-Fi
其他
前三个月
无权访问外部存储
无权访问
个性化
- 自定义正在播放控件和UI控件
+ 全选
+ Retro Music Pro
+ 购买 Retro Music Pro
+ 排序
+ 由 A 到 Z
+ 以专辑
+ 以艺术家
+ 以日期
+ 以年代
+ 由 Z 到 A
+ 仪表盘
+ 下午好
+ 祝您万事顺心
+ 晚上好
+ 专辑曲目号
+ 歌曲时长
+ 早哇
+ 移除封面
+ 晚安
+ 请问您的名字是…
+ 感谢您!
+ 经典
+ 小图标
+ 素雅
+ 保存
+ 使用语音搜索您的资料库
+ 很抱歉,您的设备暂不支持语言输入!
+ 歌曲
+ 适应
+ 简约
+ 自定义播放控件和 UI 控件
从本地选取
播放通知栏提供播放/暂停等操作
播放通知栏
@@ -201,19 +303,21 @@
锁屏
播放列表
"仅在Android 5.x(Lollipop)上可用"
- 将正在播放的歌曲专辑封面设置为锁屏壁纸
+ 将正在播放的歌曲的专辑封面设置为锁屏壁纸
系统音响起或消息提醒时降低音量
在锁屏显示模糊化的专辑封面(可能会影响第三方应用或者小部件的正常运行)
- 在正在播放界面轮播专辑封面,需要注意在卡片模式以及模糊卡片主题下无效
+ 在播放界面轮播专辑封面。需要注意,在卡片模式以及模糊卡片主题下无效
使用经典通知栏设计
- 背景色以及控件色跟随正在播放界面的专辑封面变化
+ 切换主页横幅样式
+
+ 背景色以及控件色跟随播放界面的专辑封面变化
将快捷方式颜色更改为强调色,每次颜色更改后需要切换一下该设置才能生效
- 修改导航栏颜色为主调色
+ 将主调色应用于导航栏
"\u4fee\u6539\u901a\u77e5\u680f\u989c\u8272\u4e3a\u4e13\u8f91\u5c01\u9762\u7684\u4e3b\u8272\u8c03"
从专辑封面或艺术家图中选取主色调
"在一些设备上可能会播放异常"
可以提高专辑封面的质量,但是加载时候会较慢。建议只在不满意图片分辨率时开启
- 使用Retro Music的自定义锁屏
+ 使用 Retro Music 提供的自定义锁屏
开源许可详情
对应用边缘进行圆角化
切换底部导航栏的标签标题
@@ -224,9 +328,9 @@
给迷你播放器添加额外控件
切换流派标签
显示专辑封面
- 标签标题模式
+ 底栏文字显示
专辑方格
- 带颜色的快捷方式
+ 彩色快捷方式
艺术家方格
不显示的时候降低音量
自动下载艺术家图片
@@ -234,16 +338,16 @@
选择均衡器
经典通知栏设计
自适应颜色
- 带颜色的通知栏
+ 彩色通知栏
无间隙连续播放
应用主题
- 忽略多媒体商店封面
- 上次添加播放列表到现在的间隔
+ 忽略音乐商店提供的封面
+ 您认为多久之内才算是最近添加的?
全屏控件
带颜色的导航栏
播放主题
开源许可
- 边角
+ 圆角
轮播效果
主色调
全屏应用
@@ -255,31 +359,76 @@
额外控件
主页横幅
显示流派标签
- 正在播放的专辑封面风格
+ 播放界面专辑封面风格
主颜色
评价这个应用
+ 静音时自动暂停
+ 当媒体音量降低至 0 时,音乐将自动暂停,而当您把音量提高时,则将会自动开始播放。该选项在此应用外依然可用。
删除
从黑名单中移除
- 删除简介照片
+ 移除当前头像
从播放列表中删除歌曲
从播放列表中删除歌曲
重命名播放列表
+ 始终显示
+ 显示当前页的文字
+ 不显示
保存修改
扫描媒体
- 推特
+ Twitter
+ 设置头像
+ 自动
+ 圆形
\u65e0\u6cd5\u64ad\u653e\u8fd9\u9996\u6b4c\u3002
更新图片
更新中...
版本
网络搜索
- 你想分享什么?
+ 仍处于测试阶段的高级功能
+ 您希望分享什么?
+ 主页艺术家展示形式
+ 了解我们的团队,获取我们的社交账号以及联系方式
年
+ 显示键盘
+ 堆叠
+ 渐变图片
+ 成为高级会员
+ 升级成为高级会员
+ *请在决定购买前再三考虑,如果您购买之后后悔了,恕不提供退款服务。
+ 恢复购买
+ 已恢复先前购买的内容。只需重启播放器,您就能正常使用了!
+ 已恢复先前购买的内容。
+ 正在尝试恢复先前购买的内容…
+ Retro Music 均衡器
+ 虚拟器
+ 深度
+ 垂直翻转
+ 传递
+ 水平翻转
+ 来看看这次更新的亮点吧!
+ 已保存播放列表至 %s.
+ 已扫描出 %1$d 个文件,总共有 %2$d 个
+ 睡眠定时器已取消
+ 社交媒体
+ 合页
+ 选择一个预设
+ 开启
+ 随机播放 `
+ 加入带有时间轴的歌词
+ 设置铃声
+ 请允许 Retro Music 更改音频设置
+ 推荐
+ 分享出您独一无二的 Retro Music
+ 来点音乐吧
+ 分享应用到…
+ 更多播放主题,轮播效果,色彩主题,等你解锁!
清除应用数据
错误
- 9+种播放主题
+ 窗口
+ 9 种以上播放主题
在播放界面使用轮播效果
自定义播放界面
diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml
index 8293786e..66b740c4 100644
--- a/app/src/main/res/values/strings.xml
+++ b/app/src/main/res/values/strings.xml
@@ -624,4 +624,5 @@
Now playing themes, Carousel effect, Color theme and more..
Play all
Start playing music.
+ Keyboard
diff --git a/app/src/main/res/values/styles_parents.xml b/app/src/main/res/values/styles_parents.xml
index 5c0f4980..9341c759 100644
--- a/app/src/main/res/values/styles_parents.xml
+++ b/app/src/main/res/values/styles_parents.xml
@@ -67,7 +67,7 @@
- @color/card_dark_color
- @color/dark_color
- - @color/dark_color
+ - @color/md_grey_800
- @color/ate_secondary_text_dark
diff --git a/app/src/main/res/xml/pref_general.xml b/app/src/main/res/xml/pref_general.xml
index e0d667c9..e387b795 100755
--- a/app/src/main/res/xml/pref_general.xml
+++ b/app/src/main/res/xml/pref_general.xml
@@ -2,7 +2,7 @@
-
+
-
-
+
\ No newline at end of file
diff --git a/appthemehelper/src/main/java/code/name/monkey/appthemehelper/common/prefs/supportv7/ATEListPreference.kt b/appthemehelper/src/main/java/code/name/monkey/appthemehelper/common/prefs/supportv7/ATEListPreference.kt
index b878a563..14505346 100755
--- a/appthemehelper/src/main/java/code/name/monkey/appthemehelper/common/prefs/supportv7/ATEListPreference.kt
+++ b/appthemehelper/src/main/java/code/name/monkey/appthemehelper/common/prefs/supportv7/ATEListPreference.kt
@@ -1,9 +1,11 @@
package code.name.monkey.appthemehelper.common.prefs.supportv7
import android.content.Context
+import android.graphics.PorterDuff
import android.util.AttributeSet
import androidx.preference.ListPreference
import code.name.monkey.appthemehelper.R
+import code.name.monkey.appthemehelper.ThemeStore
/**
* @author Aidan Follestad (afollestad)
@@ -27,6 +29,7 @@ class ATEListPreference : ListPreference {
}
private fun init() {
+ icon?.setColorFilter(ThemeStore.textColorSecondary(context), PorterDuff.Mode.SRC_IN)
layoutResource = R.layout.ate_preference_custom_support
if (summary == null || summary.toString().trim { it <= ' ' }.isEmpty())
summary = "%s"
diff --git a/appthemehelper/src/main/java/code/name/monkey/appthemehelper/common/prefs/supportv7/ATEPreference.kt b/appthemehelper/src/main/java/code/name/monkey/appthemehelper/common/prefs/supportv7/ATEPreference.kt
index 68f08951..7abb7053 100755
--- a/appthemehelper/src/main/java/code/name/monkey/appthemehelper/common/prefs/supportv7/ATEPreference.kt
+++ b/appthemehelper/src/main/java/code/name/monkey/appthemehelper/common/prefs/supportv7/ATEPreference.kt
@@ -1,9 +1,11 @@
package code.name.monkey.appthemehelper.common.prefs.supportv7
import android.content.Context
+import android.graphics.PorterDuff
import android.util.AttributeSet
import androidx.preference.Preference
import code.name.monkey.appthemehelper.R
+import code.name.monkey.appthemehelper.ThemeStore
/**
* @author Aidan Follestad (afollestad)
@@ -29,5 +31,6 @@ class ATEPreference : Preference {
private fun init() {
layoutResource = R.layout.ate_preference_custom_support
+ icon?.setColorFilter(ThemeStore.textColorSecondary(context), PorterDuff.Mode.SRC_IN)
}
}
\ No newline at end of file