commit
b6294db8cf
38 changed files with 282 additions and 246 deletions
|
@ -15,7 +15,7 @@ android {
|
||||||
|
|
||||||
applicationId "code.name.monkey.retromusic"
|
applicationId "code.name.monkey.retromusic"
|
||||||
versionCode 10577
|
versionCode 10577
|
||||||
versionName '5.8.3'
|
versionName '5.8.4'
|
||||||
|
|
||||||
buildConfigField("String", "GOOGLE_PLAY_LICENSING_KEY", "\"${getProperty(getProperties('../public.properties'), 'GOOGLE_PLAY_LICENSE_KEY')}\"")
|
buildConfigField("String", "GOOGLE_PLAY_LICENSING_KEY", "\"${getProperty(getProperties('../public.properties'), 'GOOGLE_PLAY_LICENSE_KEY')}\"")
|
||||||
}
|
}
|
||||||
|
@ -111,7 +111,7 @@ dependencies {
|
||||||
implementation "androidx.room:room-ktx:$room_version"
|
implementation "androidx.room:room-ktx:$room_version"
|
||||||
kapt "androidx.room:room-compiler:$room_version"
|
kapt "androidx.room:room-compiler:$room_version"
|
||||||
|
|
||||||
def lifecycle_version = "2.5.0-beta01"
|
def lifecycle_version = "2.5.0-rc01"
|
||||||
implementation "androidx.lifecycle:lifecycle-viewmodel-ktx:$lifecycle_version"
|
implementation "androidx.lifecycle:lifecycle-viewmodel-ktx:$lifecycle_version"
|
||||||
implementation "androidx.lifecycle:lifecycle-livedata-ktx:$lifecycle_version"
|
implementation "androidx.lifecycle:lifecycle-livedata-ktx:$lifecycle_version"
|
||||||
implementation "androidx.lifecycle:lifecycle-common-java8:$lifecycle_version"
|
implementation "androidx.lifecycle:lifecycle-common-java8:$lifecycle_version"
|
||||||
|
@ -139,11 +139,11 @@ dependencies {
|
||||||
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-core:$kotlin_coroutines_version"
|
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-core:$kotlin_coroutines_version"
|
||||||
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-android:$kotlin_coroutines_version"
|
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-android:$kotlin_coroutines_version"
|
||||||
|
|
||||||
def koin_version = '3.2.0-beta-1'
|
def koin_version = '3.2.0'
|
||||||
implementation "io.insert-koin:koin-core:$koin_version"
|
implementation "io.insert-koin:koin-core:$koin_version"
|
||||||
implementation "io.insert-koin:koin-android:$koin_version"
|
implementation "io.insert-koin:koin-android:$koin_version"
|
||||||
|
|
||||||
def glide_version = '4.13.1'
|
def glide_version = '4.13.2'
|
||||||
implementation "com.github.bumptech.glide:glide:$glide_version"
|
implementation "com.github.bumptech.glide:glide:$glide_version"
|
||||||
kapt "com.github.bumptech.glide:compiler:$glide_version"
|
kapt "com.github.bumptech.glide:compiler:$glide_version"
|
||||||
implementation "com.github.bumptech.glide:okhttp3-integration:$glide_version"
|
implementation "com.github.bumptech.glide:okhttp3-integration:$glide_version"
|
||||||
|
|
|
@ -3,13 +3,17 @@
|
||||||
xmlns:tools="http://schemas.android.com/tools"
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
package="code.name.monkey.retromusic">
|
package="code.name.monkey.retromusic">
|
||||||
|
|
||||||
<uses-permission android:name="android.permission.BLUETOOTH" />
|
<uses-permission
|
||||||
|
android:name="android.permission.BLUETOOTH"
|
||||||
|
android:maxSdkVersion="30" />
|
||||||
<uses-permission android:name="android.permission.DISABLE_KEYGUARD" />
|
<uses-permission android:name="android.permission.DISABLE_KEYGUARD" />
|
||||||
<uses-permission android:name="android.permission.SCHEDULE_EXACT_ALARM" />
|
<uses-permission android:name="android.permission.SCHEDULE_EXACT_ALARM" />
|
||||||
<uses-permission android:name="android.permission.VIBRATE" />
|
<uses-permission android:name="android.permission.VIBRATE" />
|
||||||
<uses-permission android:name="android.permission.WAKE_LOCK" />
|
<uses-permission android:name="android.permission.WAKE_LOCK" />
|
||||||
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
|
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
|
||||||
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
|
<uses-permission
|
||||||
|
android:name="android.permission.WRITE_EXTERNAL_STORAGE"
|
||||||
|
android:maxSdkVersion="28" />
|
||||||
<uses-permission android:name="android.permission.INTERNET" />
|
<uses-permission android:name="android.permission.INTERNET" />
|
||||||
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
|
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
|
||||||
<uses-permission android:name="android.permission.BROADCAST_STICKY" />
|
<uses-permission android:name="android.permission.BROADCAST_STICKY" />
|
||||||
|
@ -19,7 +23,7 @@
|
||||||
tools:ignore="ProtectedPermissions" />
|
tools:ignore="ProtectedPermissions" />
|
||||||
<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" />
|
<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" />
|
||||||
<uses-permission android:name="com.android.vending.BILLING" />
|
<uses-permission android:name="com.android.vending.BILLING" />
|
||||||
<uses-permission android:name="android.permission.BLUETOOTH_CONNECT"/>
|
<uses-permission android:name="android.permission.BLUETOOTH_CONNECT" />
|
||||||
|
|
||||||
<application
|
<application
|
||||||
android:name=".App"
|
android:name=".App"
|
||||||
|
@ -27,7 +31,6 @@
|
||||||
android:configChanges="locale|layoutDirection"
|
android:configChanges="locale|layoutDirection"
|
||||||
android:icon="@mipmap/ic_launcher"
|
android:icon="@mipmap/ic_launcher"
|
||||||
android:label="@string/app_name"
|
android:label="@string/app_name"
|
||||||
android:requestLegacyExternalStorage="true"
|
|
||||||
android:restoreAnyVersion="true"
|
android:restoreAnyVersion="true"
|
||||||
android:roundIcon="@mipmap/ic_launcher_round"
|
android:roundIcon="@mipmap/ic_launcher_round"
|
||||||
android:supportsRtl="true"
|
android:supportsRtl="true"
|
||||||
|
|
|
@ -62,6 +62,19 @@
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
|
<div>
|
||||||
|
<h5>May 13, 2022</h5>
|
||||||
|
<h2>v5.8.4</h2>
|
||||||
|
<h3>What's New</h3>
|
||||||
|
<ul>
|
||||||
|
<li>Added a toggle to enable/disable swipe down to dismiss mini player</li>
|
||||||
|
</ul>
|
||||||
|
<h3>Fixed</h3>
|
||||||
|
<ul>
|
||||||
|
<li>Fixed crash when adding folders to blacklist</li>
|
||||||
|
<li>Fix bugs in MD3 theme</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<h5>May 07, 2022</h5>
|
<h5>May 07, 2022</h5>
|
||||||
<h2>v5.8.3</h2>
|
<h2>v5.8.3</h2>
|
||||||
|
|
|
@ -167,4 +167,5 @@ const val SCREEN_ON_LYRICS = "screen_on_lyrics"
|
||||||
const val CIRCLE_PLAY_BUTTON = "circle_play_button"
|
const val CIRCLE_PLAY_BUTTON = "circle_play_button"
|
||||||
const val SWIPE_ANYWHERE_NOW_PLAYING = "swipe_anywhere_now_playing"
|
const val SWIPE_ANYWHERE_NOW_PLAYING = "swipe_anywhere_now_playing"
|
||||||
const val PAUSE_HISTORY = "pause_history"
|
const val PAUSE_HISTORY = "pause_history"
|
||||||
const val MANAGE_AUDIO_FOCUS = "manage_audio_focus"
|
const val MANAGE_AUDIO_FOCUS = "manage_audio_focus"
|
||||||
|
const val SWIPE_DOWN_DISMISS = "swipe_to_dismiss"
|
|
@ -148,7 +148,7 @@ class MainActivity : AbsCastActivity(), OnSharedPreferenceChangeListener {
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onSharedPreferenceChanged(sharedPreferences: SharedPreferences?, key: String?) {
|
override fun onSharedPreferenceChanged(sharedPreferences: SharedPreferences?, key: String?) {
|
||||||
if (key == GENERAL_THEME || key == MATERIAL_YOU || key == WALLPAPER_ACCENT || key == BLACK_THEME || key == ADAPTIVE_COLOR_APP || key == USER_NAME || key == TOGGLE_FULL_SCREEN || key == TOGGLE_VOLUME || key == ROUND_CORNERS || key == CAROUSEL_EFFECT || key == NOW_PLAYING_SCREEN_ID || key == TOGGLE_GENRE || key == BANNER_IMAGE_PATH || key == PROFILE_IMAGE_PATH || key == CIRCULAR_ALBUM_ART || key == KEEP_SCREEN_ON || key == TOGGLE_SEPARATE_LINE || key == TOGGLE_HOME_BANNER || key == TOGGLE_ADD_CONTROLS || key == ALBUM_COVER_STYLE || key == HOME_ARTIST_GRID_STYLE || key == ALBUM_COVER_TRANSFORM || key == DESATURATED_COLOR || key == EXTRA_SONG_INFO || key == TAB_TEXT_MODE || key == LANGUAGE_NAME || key == LIBRARY_CATEGORIES || key == CUSTOM_FONT || key == APPBAR_MODE || key == CIRCLE_PLAY_BUTTON) {
|
if (key == GENERAL_THEME || key == MATERIAL_YOU || key == WALLPAPER_ACCENT || key == BLACK_THEME || key == ADAPTIVE_COLOR_APP || key == USER_NAME || key == TOGGLE_FULL_SCREEN || key == TOGGLE_VOLUME || key == ROUND_CORNERS || key == CAROUSEL_EFFECT || key == NOW_PLAYING_SCREEN_ID || key == TOGGLE_GENRE || key == BANNER_IMAGE_PATH || key == PROFILE_IMAGE_PATH || key == CIRCULAR_ALBUM_ART || key == KEEP_SCREEN_ON || key == TOGGLE_SEPARATE_LINE || key == TOGGLE_HOME_BANNER || key == TOGGLE_ADD_CONTROLS || key == ALBUM_COVER_STYLE || key == HOME_ARTIST_GRID_STYLE || key == ALBUM_COVER_TRANSFORM || key == DESATURATED_COLOR || key == EXTRA_SONG_INFO || key == TAB_TEXT_MODE || key == LANGUAGE_NAME || key == LIBRARY_CATEGORIES || key == CUSTOM_FONT || key == APPBAR_MODE || key == CIRCLE_PLAY_BUTTON || key == SWIPE_DOWN_DISMISS) {
|
||||||
postRecreate()
|
postRecreate()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -27,10 +27,10 @@ import androidx.core.net.toUri
|
||||||
import androidx.core.text.parseAsHtml
|
import androidx.core.text.parseAsHtml
|
||||||
import androidx.core.view.isVisible
|
import androidx.core.view.isVisible
|
||||||
import code.name.monkey.appthemehelper.util.VersionUtils
|
import code.name.monkey.appthemehelper.util.VersionUtils
|
||||||
|
import code.name.monkey.retromusic.R
|
||||||
import code.name.monkey.retromusic.activities.base.AbsMusicServiceActivity
|
import code.name.monkey.retromusic.activities.base.AbsMusicServiceActivity
|
||||||
import code.name.monkey.retromusic.databinding.ActivityPermissionBinding
|
import code.name.monkey.retromusic.databinding.ActivityPermissionBinding
|
||||||
import code.name.monkey.retromusic.extensions.*
|
import code.name.monkey.retromusic.extensions.*
|
||||||
import code.name.monkey.retromusic.util.RingtoneManager
|
|
||||||
|
|
||||||
class PermissionActivity : AbsMusicServiceActivity() {
|
class PermissionActivity : AbsMusicServiceActivity() {
|
||||||
private lateinit var binding: ActivityPermissionBinding
|
private lateinit var binding: ActivityPermissionBinding
|
||||||
|
@ -49,7 +49,7 @@ class PermissionActivity : AbsMusicServiceActivity() {
|
||||||
if (VersionUtils.hasMarshmallow()) {
|
if (VersionUtils.hasMarshmallow()) {
|
||||||
binding.audioPermission.show()
|
binding.audioPermission.show()
|
||||||
binding.audioPermission.setButtonClick {
|
binding.audioPermission.setButtonClick {
|
||||||
if (RingtoneManager.requiresDialog(this@PermissionActivity)) {
|
if (hasAudioPermission()) {
|
||||||
val intent = Intent(Settings.ACTION_MANAGE_WRITE_SETTINGS)
|
val intent = Intent(Settings.ACTION_MANAGE_WRITE_SETTINGS)
|
||||||
intent.data = ("package:" + applicationContext.packageName).toUri()
|
intent.data = ("package:" + applicationContext.packageName).toUri()
|
||||||
startActivity(intent)
|
startActivity(intent)
|
||||||
|
@ -75,7 +75,8 @@ class PermissionActivity : AbsMusicServiceActivity() {
|
||||||
val color = accentColor()
|
val color = accentColor()
|
||||||
val hexColor = String.format("#%06X", 0xFFFFFF and color)
|
val hexColor = String.format("#%06X", 0xFFFFFF and color)
|
||||||
val appName =
|
val appName =
|
||||||
"Hello there! <br>Welcome to <b>Retro <span style='color:$hexColor';>Music</span></b>"
|
getString(R.string.message_welcome,
|
||||||
|
"<b>Retro <span style='color:$hexColor';>Music</span></b>")
|
||||||
.parseAsHtml()
|
.parseAsHtml()
|
||||||
binding.appNameText.text = appName
|
binding.appNameText.text = appName
|
||||||
}
|
}
|
||||||
|
@ -97,7 +98,8 @@ class PermissionActivity : AbsMusicServiceActivity() {
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun hasStoragePermission(): Boolean {
|
private fun hasStoragePermission(): Boolean {
|
||||||
return ActivityCompat.checkSelfPermission(this , Manifest.permission.READ_EXTERNAL_STORAGE) == PackageManager.PERMISSION_GRANTED
|
return ActivityCompat.checkSelfPermission(this,
|
||||||
|
Manifest.permission.READ_EXTERNAL_STORAGE) == PackageManager.PERMISSION_GRANTED
|
||||||
}
|
}
|
||||||
|
|
||||||
@RequiresApi(Build.VERSION_CODES.M)
|
@RequiresApi(Build.VERSION_CODES.M)
|
||||||
|
|
|
@ -60,7 +60,8 @@ abstract class AbsCastActivity : AbsSlidingMusicPanelActivity() {
|
||||||
mCastSession = castSession
|
mCastSession = castSession
|
||||||
webServer.start()
|
webServer.start()
|
||||||
mCastSession?.remoteMediaClient?.let {
|
mCastSession?.remoteMediaClient?.let {
|
||||||
loadCastQueue(it.mediaQueue.indexOfItemWithId(it.currentItem?.itemId ?: 0), it.approximateStreamPosition)
|
loadCastQueue(it.mediaQueue.indexOfItemWithId(it.currentItem?.itemId ?: 0),
|
||||||
|
it.approximateStreamPosition)
|
||||||
}
|
}
|
||||||
|
|
||||||
MusicPlayerRemote.isCasting = true
|
MusicPlayerRemote.isCasting = true
|
||||||
|
@ -126,7 +127,7 @@ abstract class AbsCastActivity : AbsSlidingMusicPanelActivity() {
|
||||||
progress: Long = MusicPlayerRemote.songProgressMillis.toLong(),
|
progress: Long = MusicPlayerRemote.songProgressMillis.toLong(),
|
||||||
) {
|
) {
|
||||||
mCastSession?.let {
|
mCastSession?.let {
|
||||||
if (!MusicPlayerRemote.playingQueue.isNullOrEmpty()) {
|
if (MusicPlayerRemote.playingQueue.isNotEmpty()) {
|
||||||
CastHelper.castQueue(
|
CastHelper.castQueue(
|
||||||
it,
|
it,
|
||||||
MusicPlayerRemote.playingQueue,
|
MusicPlayerRemote.playingQueue,
|
||||||
|
|
|
@ -19,6 +19,7 @@ import android.content.*
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import android.os.IBinder
|
import android.os.IBinder
|
||||||
import androidx.lifecycle.lifecycleScope
|
import androidx.lifecycle.lifecycleScope
|
||||||
|
import code.name.monkey.appthemehelper.util.VersionUtils
|
||||||
import code.name.monkey.retromusic.R
|
import code.name.monkey.retromusic.R
|
||||||
import code.name.monkey.retromusic.db.toPlayCount
|
import code.name.monkey.retromusic.db.toPlayCount
|
||||||
import code.name.monkey.retromusic.helper.MusicPlayerRemote
|
import code.name.monkey.retromusic.helper.MusicPlayerRemote
|
||||||
|
@ -188,11 +189,15 @@ abstract class AbsMusicServiceActivity : AbsBaseActivity(), IMusicServiceEventLi
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun getPermissionsToRequest(): Array<String> {
|
override fun getPermissionsToRequest(): Array<String> {
|
||||||
return arrayOf(
|
return mutableListOf(
|
||||||
Manifest.permission.READ_EXTERNAL_STORAGE,
|
Manifest.permission.READ_EXTERNAL_STORAGE,
|
||||||
Manifest.permission.WRITE_EXTERNAL_STORAGE,
|
if (VersionUtils.hasS()) Manifest.permission.BLUETOOTH_CONNECT
|
||||||
Manifest.permission.BLUETOOTH
|
else Manifest.permission.BLUETOOTH
|
||||||
)
|
).apply {
|
||||||
|
if (!VersionUtils.hasQ()) {
|
||||||
|
add(Manifest.permission.WRITE_EXTERNAL_STORAGE)
|
||||||
|
}
|
||||||
|
}.toTypedArray()
|
||||||
}
|
}
|
||||||
|
|
||||||
private class MusicStateReceiver(activity: AbsMusicServiceActivity) : BroadcastReceiver() {
|
private class MusicStateReceiver(activity: AbsMusicServiceActivity) : BroadcastReceiver() {
|
||||||
|
|
|
@ -160,7 +160,7 @@ abstract class AbsSlidingMusicPanelActivity : AbsMusicServiceActivity() {
|
||||||
private fun setupBottomSheet() {
|
private fun setupBottomSheet() {
|
||||||
bottomSheetBehavior = from(binding.slidingPanel)
|
bottomSheetBehavior = from(binding.slidingPanel)
|
||||||
bottomSheetBehavior.addBottomSheetCallback(bottomSheetCallbackList)
|
bottomSheetBehavior.addBottomSheetCallback(bottomSheetCallbackList)
|
||||||
bottomSheetBehavior.isHideable = true
|
if (PreferenceUtil.swipeDownToDismiss) bottomSheetBehavior.isHideable = true
|
||||||
setMiniPlayerAlphaProgress(0F)
|
setMiniPlayerAlphaProgress(0F)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -298,7 +298,7 @@ abstract class AbsSlidingMusicPanelActivity : AbsMusicServiceActivity() {
|
||||||
navigationBarColor = surfaceColor()
|
navigationBarColor = surfaceColor()
|
||||||
setTaskDescColor(paletteColor)
|
setTaskDescColor(paletteColor)
|
||||||
val isColorLight = paletteColor.isColorLight
|
val isColorLight = paletteColor.isColorLight
|
||||||
if (PreferenceUtil.isAdaptiveColor && (nowPlayingScreen == Normal || nowPlayingScreen == Flat || nowPlayingScreen == Material)) {
|
if (PreferenceUtil.isAdaptiveColor && (nowPlayingScreen == Normal || nowPlayingScreen == Flat || nowPlayingScreen == Material)) {
|
||||||
setLightNavigationBar(true)
|
setLightNavigationBar(true)
|
||||||
setLightStatusBar(isColorLight)
|
setLightStatusBar(isColorLight)
|
||||||
} else if (nowPlayingScreen == Card || nowPlayingScreen == Blur || nowPlayingScreen == BlurCard) {
|
} else if (nowPlayingScreen == Card || nowPlayingScreen == Blur || nowPlayingScreen == BlurCard) {
|
||||||
|
@ -357,7 +357,7 @@ abstract class AbsSlidingMusicPanelActivity : AbsMusicServiceActivity() {
|
||||||
fun setBottomNavVisibility(
|
fun setBottomNavVisibility(
|
||||||
visible: Boolean,
|
visible: Boolean,
|
||||||
animate: Boolean = false,
|
animate: Boolean = false,
|
||||||
hideBottomSheet: Boolean = MusicPlayerRemote.playingQueue.isEmpty()
|
hideBottomSheet: Boolean = MusicPlayerRemote.playingQueue.isEmpty(),
|
||||||
) {
|
) {
|
||||||
if (isInOneTabMode) {
|
if (isInOneTabMode) {
|
||||||
hideBottomSheet(
|
hideBottomSheet(
|
||||||
|
@ -391,7 +391,7 @@ abstract class AbsSlidingMusicPanelActivity : AbsMusicServiceActivity() {
|
||||||
fun hideBottomSheet(
|
fun hideBottomSheet(
|
||||||
hide: Boolean,
|
hide: Boolean,
|
||||||
animate: Boolean = false,
|
animate: Boolean = false,
|
||||||
isBottomNavVisible: Boolean = bottomNavigationView.isVisible
|
isBottomNavVisible: Boolean = bottomNavigationView.isVisible,
|
||||||
) {
|
) {
|
||||||
val heightOfBar =
|
val heightOfBar =
|
||||||
windowInsets.safeGetBottomInsets() +
|
windowInsets.safeGetBottomInsets() +
|
||||||
|
|
|
@ -31,6 +31,7 @@ import code.name.monkey.retromusic.extensions.*
|
||||||
import code.name.monkey.retromusic.util.PreferenceUtil
|
import code.name.monkey.retromusic.util.PreferenceUtil
|
||||||
import code.name.monkey.retromusic.util.theme.getNightMode
|
import code.name.monkey.retromusic.util.theme.getNightMode
|
||||||
import code.name.monkey.retromusic.util.theme.getThemeResValue
|
import code.name.monkey.retromusic.util.theme.getThemeResValue
|
||||||
|
import com.google.android.play.core.splitcompat.SplitCompat
|
||||||
import java.util.*
|
import java.util.*
|
||||||
|
|
||||||
abstract class AbsThemeActivity : ATHToolbarActivity(), Runnable {
|
abstract class AbsThemeActivity : ATHToolbarActivity(), Runnable {
|
||||||
|
@ -122,5 +123,6 @@ abstract class AbsThemeActivity : ATHToolbarActivity(), Runnable {
|
||||||
Locale.forLanguageTag(code)
|
Locale.forLanguageTag(code)
|
||||||
}
|
}
|
||||||
super.attachBaseContext(LanguageContextWrapper.wrap(newBase, locale))
|
super.attachBaseContext(LanguageContextWrapper.wrap(newBase, locale))
|
||||||
|
SplitCompat.install(this)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -154,7 +154,7 @@ class AlbumTagEditorActivity : AbsTagEditorActivity<ActivityAlbumTagEditorBindin
|
||||||
|
|
||||||
override fun onLoadFailed(errorDrawable: Drawable?) {
|
override fun onLoadFailed(errorDrawable: Drawable?) {
|
||||||
super.onLoadFailed(errorDrawable)
|
super.onLoadFailed(errorDrawable)
|
||||||
showToast("Load Failed", Toast.LENGTH_LONG)
|
showToast(R.string.error_load_failed, Toast.LENGTH_LONG)
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun setResource(resource: BitmapPaletteWrapper?) {}
|
override fun setResource(resource: BitmapPaletteWrapper?) {}
|
||||||
|
|
|
@ -193,7 +193,7 @@ class SongTagEditorActivity : AbsTagEditorActivity<ActivitySongTagEditorBinding>
|
||||||
|
|
||||||
override fun onLoadFailed(errorDrawable: Drawable?) {
|
override fun onLoadFailed(errorDrawable: Drawable?) {
|
||||||
super.onLoadFailed(errorDrawable)
|
super.onLoadFailed(errorDrawable)
|
||||||
showToast("Load Failed", Toast.LENGTH_LONG)
|
showToast(R.string.error_load_failed, Toast.LENGTH_LONG)
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun setResource(resource: BitmapPaletteWrapper?) {}
|
override fun setResource(resource: BitmapPaletteWrapper?) {}
|
||||||
|
|
|
@ -39,7 +39,7 @@ object CastHelper {
|
||||||
val remoteMediaClient = castSession.remoteMediaClient
|
val remoteMediaClient = castSession.remoteMediaClient
|
||||||
remoteMediaClient?.queueLoad(
|
remoteMediaClient?.queueLoad(
|
||||||
songs.toMediaInfoList(),
|
songs.toMediaInfoList(),
|
||||||
position,
|
if (position != -1) position else 0,
|
||||||
MediaStatus.REPEAT_MODE_REPEAT_OFF,
|
MediaStatus.REPEAT_MODE_REPEAT_OFF,
|
||||||
progress,
|
progress,
|
||||||
JSONObject()
|
JSONObject()
|
||||||
|
|
|
@ -2,6 +2,7 @@ package code.name.monkey.retromusic.dialogs
|
||||||
|
|
||||||
import android.Manifest
|
import android.Manifest
|
||||||
import android.app.Dialog
|
import android.app.Dialog
|
||||||
|
import android.content.Context
|
||||||
import android.content.pm.PackageManager
|
import android.content.pm.PackageManager
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import androidx.core.app.ActivityCompat
|
import androidx.core.app.ActivityCompat
|
||||||
|
@ -80,7 +81,7 @@ class BlacklistFolderChooserDialog : DialogFragment() {
|
||||||
}
|
}
|
||||||
.noAutoDismiss()
|
.noAutoDismiss()
|
||||||
.positiveButton(res = R.string.add_action) {
|
.positiveButton(res = R.string.add_action) {
|
||||||
callback?.onFolderSelection(this@BlacklistFolderChooserDialog, parentFolder!!)
|
callback?.onFolderSelection(requireContext(), parentFolder!!)
|
||||||
dismiss()
|
dismiss()
|
||||||
}
|
}
|
||||||
.negativeButton(res = android.R.string.cancel) { dismiss() }
|
.negativeButton(res = android.R.string.cancel) { dismiss() }
|
||||||
|
@ -128,7 +129,7 @@ class BlacklistFolderChooserDialog : DialogFragment() {
|
||||||
}
|
}
|
||||||
|
|
||||||
interface FolderCallback {
|
interface FolderCallback {
|
||||||
fun onFolderSelection(dialog: BlacklistFolderChooserDialog, folder: File)
|
fun onFolderSelection(context: Context, folder: File)
|
||||||
}
|
}
|
||||||
|
|
||||||
companion object {
|
companion object {
|
||||||
|
|
|
@ -1,6 +1,20 @@
|
||||||
package code.name.monkey.retromusic.extensions
|
package code.name.monkey.retromusic.extensions
|
||||||
|
|
||||||
|
import android.support.v4.media.MediaDescriptionCompat
|
||||||
|
import android.support.v4.media.session.MediaSessionCompat.QueueItem
|
||||||
import code.name.monkey.retromusic.model.Song
|
import code.name.monkey.retromusic.model.Song
|
||||||
import code.name.monkey.retromusic.util.MusicUtil
|
import code.name.monkey.retromusic.util.MusicUtil
|
||||||
|
|
||||||
val Song.uri get() = MusicUtil.getSongFileUri(songId = id)
|
val Song.uri get() = MusicUtil.getSongFileUri(songId = id)
|
||||||
|
|
||||||
|
|
||||||
|
fun ArrayList<Song>.toMediaSessionQueue(): List<QueueItem> {
|
||||||
|
return map {
|
||||||
|
val mediaDescription = MediaDescriptionCompat.Builder()
|
||||||
|
.setMediaId(it.id.toString())
|
||||||
|
.setTitle(it.title)
|
||||||
|
.setSubtitle(it.artistName)
|
||||||
|
.build()
|
||||||
|
QueueItem(mediaDescription, it.hashCode().toLong())
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
|
@ -122,7 +122,7 @@ class BackupFragment : Fragment(R.layout.fragment_backup), BackupAdapter.BackupC
|
||||||
try {
|
try {
|
||||||
file.delete()
|
file.delete()
|
||||||
} catch (exception: SecurityException) {
|
} catch (exception: SecurityException) {
|
||||||
showToast("Could not delete backup")
|
showToast(R.string.error_delete_backup)
|
||||||
}
|
}
|
||||||
backupViewModel.loadBackups()
|
backupViewModel.loadBackups()
|
||||||
return true
|
return true
|
||||||
|
@ -147,7 +147,7 @@ class BackupFragment : Fragment(R.layout.fragment_backup), BackupAdapter.BackupC
|
||||||
file.renameTo(renamedFile)
|
file.renameTo(renamedFile)
|
||||||
backupViewModel.loadBackups()
|
backupViewModel.loadBackups()
|
||||||
} else {
|
} else {
|
||||||
showToast("File already exists")
|
showToast(R.string.file_already_exists)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
positiveButton(android.R.string.ok)
|
positiveButton(android.R.string.ok)
|
||||||
|
|
|
@ -180,11 +180,14 @@ abstract class AbsPlayerFragment(@LayoutRes layout: Int) : AbsMusicServiceFragme
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
R.id.action_set_as_ringtone -> {
|
R.id.action_set_as_ringtone -> {
|
||||||
if (RingtoneManager.requiresDialog(requireActivity())) {
|
requireContext().run {
|
||||||
RingtoneManager.getDialog(requireActivity())
|
if (RingtoneManager.requiresDialog(this)) {
|
||||||
|
RingtoneManager.showDialog(this)
|
||||||
|
} else {
|
||||||
|
RingtoneManager.setRingtone(this, song)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
val ringtoneManager = RingtoneManager(requireActivity())
|
|
||||||
ringtoneManager.setRingtone(song)
|
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
R.id.action_go_to_genre -> {
|
R.id.action_go_to_genre -> {
|
||||||
|
@ -265,7 +268,7 @@ abstract class AbsPlayerFragment(@LayoutRes layout: Int) : AbsMusicServiceFragme
|
||||||
} else {
|
} else {
|
||||||
if (isFavorite) R.drawable.ic_favorite else R.drawable.ic_favorite_border
|
if (isFavorite) R.drawable.ic_favorite else R.drawable.ic_favorite_border
|
||||||
}
|
}
|
||||||
val drawable = requireContext().getTintedDrawable(
|
val drawable = requireContext().getTintedDrawable(
|
||||||
icon,
|
icon,
|
||||||
toolbarIconColor()
|
toolbarIconColor()
|
||||||
)
|
)
|
||||||
|
@ -379,9 +382,7 @@ fun goToArtist(activity: Activity) {
|
||||||
findNavController(R.id.fragment_container).navigate(
|
findNavController(R.id.fragment_container).navigate(
|
||||||
R.id.artistDetailsFragment,
|
R.id.artistDetailsFragment,
|
||||||
bundleOf(EXTRA_ARTIST_ID to song.artistId),
|
bundleOf(EXTRA_ARTIST_ID to song.artistId),
|
||||||
navOptions {
|
null,
|
||||||
launchSingleTop = true
|
|
||||||
},
|
|
||||||
null
|
null
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
@ -402,9 +403,7 @@ fun goToAlbum(activity: Activity) {
|
||||||
findNavController(R.id.fragment_container).navigate(
|
findNavController(R.id.fragment_container).navigate(
|
||||||
R.id.albumDetailsFragment,
|
R.id.albumDetailsFragment,
|
||||||
bundleOf(EXTRA_ALBUM_ID to song.albumId),
|
bundleOf(EXTRA_ALBUM_ID to song.albumId),
|
||||||
navOptions {
|
null,
|
||||||
launchSingleTop = true
|
|
||||||
},
|
|
||||||
null
|
null
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
|
@ -141,8 +141,8 @@ class LyricsFragment : AbsMainActivityFragment(R.layout.fragment_lyrics) {
|
||||||
binding.lyricsPager.adapter = lyricsSectionsAdapter
|
binding.lyricsPager.adapter = lyricsSectionsAdapter
|
||||||
TabLayoutMediator(binding.tabLyrics, binding.lyricsPager) { tab, position ->
|
TabLayoutMediator(binding.tabLyrics, binding.lyricsPager) { tab, position ->
|
||||||
tab.text = when (position) {
|
tab.text = when (position) {
|
||||||
0 -> "Synced Lyrics"
|
0 -> getString(R.string.synced_lyrics)
|
||||||
1 -> "Normal Lyrics"
|
1 -> getString(R.string.normal_lyrics)
|
||||||
else -> ""
|
else -> ""
|
||||||
}
|
}
|
||||||
}.attach()
|
}.attach()
|
||||||
|
@ -383,7 +383,7 @@ class LyricsFragment : AbsMainActivityFragment(R.layout.fragment_lyrics) {
|
||||||
}
|
}
|
||||||
|
|
||||||
fun loadLRCLyrics() {
|
fun loadLRCLyrics() {
|
||||||
binding.lyricsView.setLabel("Empty")
|
binding.lyricsView.setLabel(getString(R.string.empty))
|
||||||
LyricUtil.getSyncedLyricsFile(MusicPlayerRemote.currentSong)?.let {
|
LyricUtil.getSyncedLyricsFile(MusicPlayerRemote.currentSong)?.let {
|
||||||
binding.lyricsView.loadLrc(it)
|
binding.lyricsView.loadLrc(it)
|
||||||
}
|
}
|
||||||
|
|
|
@ -66,7 +66,7 @@ class UserInfoFragment : Fragment() {
|
||||||
override fun onCreateView(
|
override fun onCreateView(
|
||||||
inflater: LayoutInflater,
|
inflater: LayoutInflater,
|
||||||
container: ViewGroup?,
|
container: ViewGroup?,
|
||||||
savedInstanceState: Bundle?
|
savedInstanceState: Bundle?,
|
||||||
): View {
|
): View {
|
||||||
sharedElementEnterTransition = MaterialContainerTransform().apply {
|
sharedElementEnterTransition = MaterialContainerTransform().apply {
|
||||||
drawingViewId = R.id.fragment_container
|
drawingViewId = R.id.fragment_container
|
||||||
|
@ -96,7 +96,7 @@ class UserInfoFragment : Fragment() {
|
||||||
binding.next.setOnClickListener {
|
binding.next.setOnClickListener {
|
||||||
val nameString = binding.name.text.toString().trim { it <= ' ' }
|
val nameString = binding.name.text.toString().trim { it <= ' ' }
|
||||||
if (nameString.isEmpty()) {
|
if (nameString.isEmpty()) {
|
||||||
showToast("Your name can't be empty!")
|
showToast(R.string.error_empty_name)
|
||||||
return@setOnClickListener
|
return@setOnClickListener
|
||||||
}
|
}
|
||||||
userName = nameString
|
userName = nameString
|
||||||
|
@ -229,7 +229,7 @@ class UserInfoFragment : Fragment() {
|
||||||
model: Any?,
|
model: Any?,
|
||||||
target: Target<Bitmap>?,
|
target: Target<Bitmap>?,
|
||||||
dataSource: DataSource?,
|
dataSource: DataSource?,
|
||||||
isFirstResource: Boolean
|
isFirstResource: Boolean,
|
||||||
): Boolean {
|
): Boolean {
|
||||||
resource?.let { saveImage(it, USER_BANNER) }
|
resource?.let { saveImage(it, USER_BANNER) }
|
||||||
return false
|
return false
|
||||||
|
@ -239,7 +239,7 @@ class UserInfoFragment : Fragment() {
|
||||||
e: GlideException?,
|
e: GlideException?,
|
||||||
model: Any?,
|
model: Any?,
|
||||||
target: Target<Bitmap>?,
|
target: Target<Bitmap>?,
|
||||||
isFirstResource: Boolean
|
isFirstResource: Boolean,
|
||||||
): Boolean {
|
): Boolean {
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
@ -251,18 +251,14 @@ class UserInfoFragment : Fragment() {
|
||||||
lifecycleScope.launch(Dispatchers.IO) {
|
lifecycleScope.launch(Dispatchers.IO) {
|
||||||
val appDir = requireContext().filesDir
|
val appDir = requireContext().filesDir
|
||||||
val file = File(appDir, fileName)
|
val file = File(appDir, fileName)
|
||||||
var successful = false
|
var successful: Boolean
|
||||||
runCatching {
|
file.outputStream().buffered().use {
|
||||||
file.outputStream().buffered().use {
|
successful = ImageUtil.resizeBitmap(bitmap, 2048)
|
||||||
successful = ImageUtil.resizeBitmap(bitmap, 2048)
|
.compress(Bitmap.CompressFormat.WEBP, 100, it)
|
||||||
.compress(Bitmap.CompressFormat.WEBP, 100, it)
|
|
||||||
}
|
|
||||||
}.onFailure {
|
|
||||||
it.printStackTrace()
|
|
||||||
}
|
}
|
||||||
if (successful) {
|
if (successful) {
|
||||||
withContext(Dispatchers.Main) {
|
withContext(Dispatchers.Main) {
|
||||||
showToast("Updated")
|
showToast(R.string.message_updated)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -279,7 +275,7 @@ class UserInfoFragment : Fragment() {
|
||||||
model: Any?,
|
model: Any?,
|
||||||
target: Target<Bitmap>?,
|
target: Target<Bitmap>?,
|
||||||
dataSource: DataSource?,
|
dataSource: DataSource?,
|
||||||
isFirstResource: Boolean
|
isFirstResource: Boolean,
|
||||||
): Boolean {
|
): Boolean {
|
||||||
resource?.let { saveImage(it, USER_PROFILE) }
|
resource?.let { saveImage(it, USER_PROFILE) }
|
||||||
return false
|
return false
|
||||||
|
@ -289,7 +285,7 @@ class UserInfoFragment : Fragment() {
|
||||||
e: GlideException?,
|
e: GlideException?,
|
||||||
model: Any?,
|
model: Any?,
|
||||||
target: Target<Bitmap>?,
|
target: Target<Bitmap>?,
|
||||||
isFirstResource: Boolean
|
isFirstResource: Boolean,
|
||||||
): Boolean {
|
): Boolean {
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
|
@ -20,11 +20,13 @@ import android.content.SharedPreferences
|
||||||
import android.graphics.Color
|
import android.graphics.Color
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import android.view.View
|
import android.view.View
|
||||||
|
import androidx.annotation.ColorInt
|
||||||
import androidx.core.animation.doOnEnd
|
import androidx.core.animation.doOnEnd
|
||||||
import androidx.core.view.isVisible
|
import androidx.core.view.isVisible
|
||||||
import androidx.lifecycle.lifecycleScope
|
import androidx.lifecycle.lifecycleScope
|
||||||
import androidx.preference.PreferenceManager
|
import androidx.preference.PreferenceManager
|
||||||
import androidx.viewpager.widget.ViewPager
|
import androidx.viewpager.widget.ViewPager
|
||||||
|
import code.name.monkey.appthemehelper.util.ColorUtil
|
||||||
import code.name.monkey.appthemehelper.util.MaterialValueHelper
|
import code.name.monkey.appthemehelper.util.MaterialValueHelper
|
||||||
import code.name.monkey.retromusic.LYRICS_TYPE
|
import code.name.monkey.retromusic.LYRICS_TYPE
|
||||||
import code.name.monkey.retromusic.R
|
import code.name.monkey.retromusic.R
|
||||||
|
@ -195,15 +197,7 @@ class PlayerAlbumCoverFragment : AbsMusicServiceFragment(R.layout.fragment_playe
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun setLRCViewColors(backgroundColor: Int) {
|
private fun setLRCViewColors(@ColorInt primaryColor: Int, @ColorInt secondaryColor: Int) {
|
||||||
val primaryColor = MaterialValueHelper.getPrimaryTextColor(
|
|
||||||
requireContext(),
|
|
||||||
backgroundColor.isColorLight
|
|
||||||
)
|
|
||||||
val secondaryColor = MaterialValueHelper.getSecondaryDisabledTextColor(
|
|
||||||
requireContext(),
|
|
||||||
backgroundColor.isColorLight
|
|
||||||
)
|
|
||||||
lrcView.apply {
|
lrcView.apply {
|
||||||
setCurrentColor(primaryColor)
|
setCurrentColor(primaryColor)
|
||||||
setTimeTextColor(primaryColor)
|
setTimeTextColor(primaryColor)
|
||||||
|
@ -277,19 +271,25 @@ class PlayerAlbumCoverFragment : AbsMusicServiceFragment(R.layout.fragment_playe
|
||||||
|
|
||||||
private fun notifyColorChange(color: MediaNotificationProcessor) {
|
private fun notifyColorChange(color: MediaNotificationProcessor) {
|
||||||
callbacks?.onColorChanged(color)
|
callbacks?.onColorChanged(color)
|
||||||
setLRCViewColors(
|
val primaryColor = MaterialValueHelper.getPrimaryTextColor(
|
||||||
when (PreferenceUtil.nowPlayingScreen) {
|
requireContext(),
|
||||||
Adaptive, Fit, Plain, Simple -> surfaceColor()
|
surfaceColor().isColorLight
|
||||||
Flat, Normal, Material -> if (PreferenceUtil.isAdaptiveColor) {
|
|
||||||
color.backgroundColor
|
|
||||||
} else {
|
|
||||||
surfaceColor()
|
|
||||||
}
|
|
||||||
Color, Classic -> color.primaryTextColor
|
|
||||||
Blur -> Color.BLACK
|
|
||||||
else -> surfaceColor()
|
|
||||||
}
|
|
||||||
)
|
)
|
||||||
|
val secondaryColor = MaterialValueHelper.getSecondaryDisabledTextColor(
|
||||||
|
requireContext(),
|
||||||
|
surfaceColor().isColorLight
|
||||||
|
)
|
||||||
|
|
||||||
|
when (PreferenceUtil.nowPlayingScreen) {
|
||||||
|
Flat, Normal, Material -> if (PreferenceUtil.isAdaptiveColor) {
|
||||||
|
setLRCViewColors(color.primaryTextColor, color.secondaryTextColor)
|
||||||
|
} else {
|
||||||
|
setLRCViewColors(primaryColor, secondaryColor)
|
||||||
|
}
|
||||||
|
Color, Classic -> setLRCViewColors(color.primaryTextColor, color.secondaryTextColor)
|
||||||
|
Blur -> setLRCViewColors(Color.WHITE, ColorUtil.withAlpha(Color.WHITE, 0.5f))
|
||||||
|
else -> setLRCViewColors(primaryColor, secondaryColor)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
fun setCallbacks(listener: Callbacks) {
|
fun setCallbacks(listener: Callbacks) {
|
||||||
|
@ -308,5 +308,5 @@ class PlayerAlbumCoverFragment : AbsMusicServiceFragment(R.layout.fragment_playe
|
||||||
}
|
}
|
||||||
|
|
||||||
private val lyricViewNpsList =
|
private val lyricViewNpsList =
|
||||||
listOf(Blur, Classic, Color, Flat, Material, Normal, Plain, Simple)
|
listOf(Blur, Classic, Color, Flat, Material, MD3, Normal, Plain, Simple)
|
||||||
}
|
}
|
||||||
|
|
|
@ -17,12 +17,10 @@ package code.name.monkey.retromusic.fragments.player.md3
|
||||||
import android.animation.ObjectAnimator
|
import android.animation.ObjectAnimator
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import android.view.View
|
import android.view.View
|
||||||
import android.view.animation.DecelerateInterpolator
|
|
||||||
import android.view.animation.LinearInterpolator
|
import android.view.animation.LinearInterpolator
|
||||||
import android.widget.ImageButton
|
import android.widget.ImageButton
|
||||||
import android.widget.SeekBar
|
import android.widget.SeekBar
|
||||||
import android.widget.TextView
|
import android.widget.TextView
|
||||||
import code.name.monkey.appthemehelper.ThemeStore
|
|
||||||
import code.name.monkey.appthemehelper.util.ATHUtil
|
import code.name.monkey.appthemehelper.util.ATHUtil
|
||||||
import code.name.monkey.appthemehelper.util.ColorUtil
|
import code.name.monkey.appthemehelper.util.ColorUtil
|
||||||
import code.name.monkey.appthemehelper.util.MaterialValueHelper
|
import code.name.monkey.appthemehelper.util.MaterialValueHelper
|
||||||
|
@ -108,11 +106,7 @@ class MD3PlaybackControlsFragment :
|
||||||
MaterialValueHelper.getPrimaryDisabledTextColor(requireContext(), false)
|
MaterialValueHelper.getPrimaryDisabledTextColor(requireContext(), false)
|
||||||
}
|
}
|
||||||
|
|
||||||
val colorFinal = if (PreferenceUtil.isAdaptiveColor) {
|
val colorFinal = accentColor().ripAlpha()
|
||||||
color.primaryTextColor
|
|
||||||
} else {
|
|
||||||
ThemeStore.accentColor(requireContext())
|
|
||||||
}.ripAlpha()
|
|
||||||
|
|
||||||
TintHelper.setTintAuto(
|
TintHelper.setTintAuto(
|
||||||
binding.playPauseButton,
|
binding.playPauseButton,
|
||||||
|
@ -198,22 +192,9 @@ class MD3PlaybackControlsFragment :
|
||||||
setUpPlayPauseFab()
|
setUpPlayPauseFab()
|
||||||
}
|
}
|
||||||
|
|
||||||
public override fun show() {
|
public override fun show() {}
|
||||||
binding.playPauseButton.animate()
|
|
||||||
.scaleX(1f)
|
|
||||||
.scaleY(1f)
|
|
||||||
.rotation(360f)
|
|
||||||
.setInterpolator(DecelerateInterpolator())
|
|
||||||
.start()
|
|
||||||
}
|
|
||||||
|
|
||||||
public override fun hide() {
|
public override fun hide() {}
|
||||||
binding.playPauseButton.apply {
|
|
||||||
scaleX = 0f
|
|
||||||
scaleY = 0f
|
|
||||||
rotation = 0f
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onUpdateProgressViews(progress: Int, total: Int) {
|
override fun onUpdateProgressViews(progress: Int, total: Int) {
|
||||||
binding.progressSlider.max = total
|
binding.progressSlider.max = total
|
||||||
|
|
|
@ -24,6 +24,7 @@ import androidx.preference.Preference
|
||||||
import androidx.preference.PreferenceManager
|
import androidx.preference.PreferenceManager
|
||||||
import code.name.monkey.appthemehelper.common.prefs.supportv7.ATEPreferenceFragmentCompat
|
import code.name.monkey.appthemehelper.common.prefs.supportv7.ATEPreferenceFragmentCompat
|
||||||
import code.name.monkey.appthemehelper.util.VersionUtils
|
import code.name.monkey.appthemehelper.util.VersionUtils
|
||||||
|
import code.name.monkey.retromusic.R
|
||||||
import code.name.monkey.retromusic.activities.OnThemeChangedListener
|
import code.name.monkey.retromusic.activities.OnThemeChangedListener
|
||||||
import code.name.monkey.retromusic.extensions.showToast
|
import code.name.monkey.retromusic.extensions.showToast
|
||||||
import code.name.monkey.retromusic.preferences.*
|
import code.name.monkey.retromusic.preferences.*
|
||||||
|
@ -37,7 +38,7 @@ import dev.chrisbanes.insetter.applyInsetter
|
||||||
abstract class AbsSettingsFragment : ATEPreferenceFragmentCompat() {
|
abstract class AbsSettingsFragment : ATEPreferenceFragmentCompat() {
|
||||||
|
|
||||||
internal fun showProToastAndNavigate(message: String) {
|
internal fun showProToastAndNavigate(message: String) {
|
||||||
showToast("$message is Pro version feature.")
|
showToast(getString(R.string.message_pro_feature, message))
|
||||||
NavigationUtil.goToProVersion(requireActivity())
|
NavigationUtil.goToProVersion(requireActivity())
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -139,9 +139,7 @@ class SongsFragment : AbsRecyclerViewCustomGridSizeFragment<SongAdapter, GridLay
|
||||||
CastButtonFactory.setUpMediaRouteButton(requireContext(), menu, R.id.action_cast)
|
CastButtonFactory.setUpMediaRouteButton(requireContext(), menu, R.id.action_cast)
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun setUpSortOrderMenu(
|
private fun setUpSortOrderMenu(sortOrderMenu: SubMenu) {
|
||||||
sortOrderMenu: SubMenu
|
|
||||||
) {
|
|
||||||
val currentSortOrder: String? = getSortOrder()
|
val currentSortOrder: String? = getSortOrder()
|
||||||
sortOrderMenu.clear()
|
sortOrderMenu.clear()
|
||||||
sortOrderMenu.add(
|
sortOrderMenu.add(
|
||||||
|
@ -211,9 +209,7 @@ class SongsFragment : AbsRecyclerViewCustomGridSizeFragment<SongAdapter, GridLay
|
||||||
sortOrderMenu.setGroupCheckable(0, true, true)
|
sortOrderMenu.setGroupCheckable(0, true, true)
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun setupLayoutMenu(
|
private fun setupLayoutMenu(subMenu: SubMenu) {
|
||||||
subMenu: SubMenu
|
|
||||||
) {
|
|
||||||
when (itemLayoutRes()) {
|
when (itemLayoutRes()) {
|
||||||
R.layout.item_card -> subMenu.findItem(R.id.action_layout_card).isChecked = true
|
R.layout.item_card -> subMenu.findItem(R.id.action_layout_card).isChecked = true
|
||||||
R.layout.item_grid -> subMenu.findItem(R.id.action_layout_normal).isChecked = true
|
R.layout.item_grid -> subMenu.findItem(R.id.action_layout_normal).isChecked = true
|
||||||
|
@ -227,9 +223,7 @@ class SongsFragment : AbsRecyclerViewCustomGridSizeFragment<SongAdapter, GridLay
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun setUpGridSizeMenu(
|
private fun setUpGridSizeMenu(gridSizeMenu: SubMenu) {
|
||||||
gridSizeMenu: SubMenu
|
|
||||||
) {
|
|
||||||
when (getGridSize()) {
|
when (getGridSize()) {
|
||||||
1 -> gridSizeMenu.findItem(R.id.action_grid_size_1).isChecked = true
|
1 -> gridSizeMenu.findItem(R.id.action_grid_size_1).isChecked = true
|
||||||
2 -> gridSizeMenu.findItem(R.id.action_grid_size_2).isChecked = true
|
2 -> gridSizeMenu.findItem(R.id.action_grid_size_2).isChecked = true
|
||||||
|
@ -274,9 +268,7 @@ class SongsFragment : AbsRecyclerViewCustomGridSizeFragment<SongAdapter, GridLay
|
||||||
return super.onMenuItemSelected(item)
|
return super.onMenuItemSelected(item)
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun handleSortOrderMenuItem(
|
private fun handleSortOrderMenuItem(item: MenuItem): Boolean {
|
||||||
item: MenuItem
|
|
||||||
): Boolean {
|
|
||||||
val sortOrder: String = when (item.itemId) {
|
val sortOrder: String = when (item.itemId) {
|
||||||
R.id.action_song_sort_order_asc -> SongSortOrder.SONG_A_Z
|
R.id.action_song_sort_order_asc -> SongSortOrder.SONG_A_Z
|
||||||
R.id.action_song_sort_order_desc -> SongSortOrder.SONG_Z_A
|
R.id.action_song_sort_order_desc -> SongSortOrder.SONG_Z_A
|
||||||
|
@ -297,9 +289,7 @@ class SongsFragment : AbsRecyclerViewCustomGridSizeFragment<SongAdapter, GridLay
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun handleLayoutResType(
|
private fun handleLayoutResType(item: MenuItem): Boolean {
|
||||||
item: MenuItem
|
|
||||||
): Boolean {
|
|
||||||
val layoutRes = when (item.itemId) {
|
val layoutRes = when (item.itemId) {
|
||||||
R.id.action_layout_normal -> R.layout.item_grid
|
R.id.action_layout_normal -> R.layout.item_grid
|
||||||
R.id.action_layout_card -> R.layout.item_card
|
R.id.action_layout_card -> R.layout.item_card
|
||||||
|
@ -317,9 +307,7 @@ class SongsFragment : AbsRecyclerViewCustomGridSizeFragment<SongAdapter, GridLay
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun handleGridSizeMenuItem(
|
private fun handleGridSizeMenuItem(item: MenuItem): Boolean {
|
||||||
item: MenuItem
|
|
||||||
): Boolean {
|
|
||||||
val gridSize = when (item.itemId) {
|
val gridSize = when (item.itemId) {
|
||||||
R.id.action_grid_size_1 -> 1
|
R.id.action_grid_size_1 -> 1
|
||||||
R.id.action_grid_size_2 -> 2
|
R.id.action_grid_size_2 -> 2
|
||||||
|
|
|
@ -3,6 +3,7 @@ package code.name.monkey.retromusic.helper
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.os.Environment
|
import android.os.Environment
|
||||||
import code.name.monkey.retromusic.BuildConfig
|
import code.name.monkey.retromusic.BuildConfig
|
||||||
|
import code.name.monkey.retromusic.R
|
||||||
import code.name.monkey.retromusic.db.PlaylistEntity
|
import code.name.monkey.retromusic.db.PlaylistEntity
|
||||||
import code.name.monkey.retromusic.db.toSongEntity
|
import code.name.monkey.retromusic.db.toSongEntity
|
||||||
import code.name.monkey.retromusic.extensions.showToast
|
import code.name.monkey.retromusic.extensions.showToast
|
||||||
|
@ -57,11 +58,11 @@ object BackupHelper : KoinComponent {
|
||||||
}
|
}
|
||||||
}.onFailure {
|
}.onFailure {
|
||||||
withContext(Dispatchers.Main) {
|
withContext(Dispatchers.Main) {
|
||||||
context.showToast("Couldn't create backup")
|
context.showToast(R.string.error_create_backup)
|
||||||
}
|
}
|
||||||
}.onSuccess {
|
}.onSuccess {
|
||||||
withContext(Dispatchers.Main) {
|
withContext(Dispatchers.Main) {
|
||||||
context.showToast("Backup created successfully")
|
context.showToast(R.string.message_backup_create_success)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -160,7 +161,7 @@ object BackupHelper : KoinComponent {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
withContext(Dispatchers.Main) {
|
withContext(Dispatchers.Main) {
|
||||||
context.showToast("Restore Completed Successfully")
|
context.showToast(R.string.message_restore_success)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -55,10 +55,9 @@ object SongMenuHelper : KoinComponent {
|
||||||
when (menuItemId) {
|
when (menuItemId) {
|
||||||
R.id.action_set_as_ringtone -> {
|
R.id.action_set_as_ringtone -> {
|
||||||
if (RingtoneManager.requiresDialog(activity)) {
|
if (RingtoneManager.requiresDialog(activity)) {
|
||||||
RingtoneManager.getDialog(activity)
|
RingtoneManager.showDialog(activity)
|
||||||
} else {
|
} else {
|
||||||
val ringtoneManager = RingtoneManager(activity)
|
RingtoneManager.setRingtone(activity, song)
|
||||||
ringtoneManager.setRingtone(song)
|
|
||||||
}
|
}
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
|
@ -38,7 +38,7 @@ class BlacklistPreference @JvmOverloads constructor(
|
||||||
context: Context,
|
context: Context,
|
||||||
attrs: AttributeSet? = null,
|
attrs: AttributeSet? = null,
|
||||||
defStyleAttr: Int = -1,
|
defStyleAttr: Int = -1,
|
||||||
defStyleRes: Int = -1
|
defStyleRes: Int = -1,
|
||||||
) : ATEDialogPreference(context, attrs, defStyleAttr, defStyleRes) {
|
) : ATEDialogPreference(context, attrs, defStyleAttr, defStyleRes) {
|
||||||
|
|
||||||
init {
|
init {
|
||||||
|
@ -123,8 +123,7 @@ class BlacklistPreferenceDialog : DialogFragment(), BlacklistFolderChooserDialog
|
||||||
dialog?.setItems(paths.toTypedArray(), null)
|
dialog?.setItems(paths.toTypedArray(), null)
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onFolderSelection(dialog: BlacklistFolderChooserDialog, folder: File) {
|
override fun onFolderSelection(context: Context, folder: File) {
|
||||||
BlacklistStore.getInstance(requireContext()).addPath(folder)
|
BlacklistStore.getInstance(context).addPath(folder)
|
||||||
refreshBlacklistData()
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -76,7 +76,7 @@ class LibraryPreferenceDialog : DialogFragment() {
|
||||||
private fun updateCategories(categories: List<CategoryInfo>) {
|
private fun updateCategories(categories: List<CategoryInfo>) {
|
||||||
if (getSelected(categories) == 0) return
|
if (getSelected(categories) == 0) return
|
||||||
if (getSelected(categories) > 5) {
|
if (getSelected(categories) > 5) {
|
||||||
showToast("Not more than 5 items")
|
showToast(R.string.message_limit_tabs)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
PreferenceUtil.libraryCategory = categories
|
PreferenceUtil.libraryCategory = categories
|
||||||
|
|
|
@ -56,6 +56,7 @@ import code.name.monkey.retromusic.appwidgets.*
|
||||||
import code.name.monkey.retromusic.auto.AutoMediaIDHelper
|
import code.name.monkey.retromusic.auto.AutoMediaIDHelper
|
||||||
import code.name.monkey.retromusic.auto.AutoMusicProvider
|
import code.name.monkey.retromusic.auto.AutoMusicProvider
|
||||||
import code.name.monkey.retromusic.extensions.showToast
|
import code.name.monkey.retromusic.extensions.showToast
|
||||||
|
import code.name.monkey.retromusic.extensions.toMediaSessionQueue
|
||||||
import code.name.monkey.retromusic.glide.BlurTransformation
|
import code.name.monkey.retromusic.glide.BlurTransformation
|
||||||
import code.name.monkey.retromusic.glide.GlideApp
|
import code.name.monkey.retromusic.glide.GlideApp
|
||||||
import code.name.monkey.retromusic.glide.RetroGlideExtension.getDefaultTransition
|
import code.name.monkey.retromusic.glide.RetroGlideExtension.getDefaultTransition
|
||||||
|
@ -1225,6 +1226,8 @@ class MusicService : MediaBrowserServiceCompat(),
|
||||||
songPlayCountHelper.notifySongChanged(currentSong)
|
songPlayCountHelper.notifySongChanged(currentSong)
|
||||||
}
|
}
|
||||||
QUEUE_CHANGED -> {
|
QUEUE_CHANGED -> {
|
||||||
|
mediaSession?.setQueueTitle(getString(R.string.now_playing_queue))
|
||||||
|
mediaSession?.setQueue(playingQueue.toMediaSessionQueue())
|
||||||
updateMediaSessionMetaData() // because playing queue size might have changed
|
updateMediaSessionMetaData() // because playing queue size might have changed
|
||||||
saveState()
|
saveState()
|
||||||
if (playingQueue.size > 0) {
|
if (playingQueue.size > 0) {
|
||||||
|
|
|
@ -22,6 +22,7 @@ import android.provider.MediaStore
|
||||||
import android.widget.Toast
|
import android.widget.Toast
|
||||||
import androidx.core.content.edit
|
import androidx.core.content.edit
|
||||||
import code.name.monkey.retromusic.App
|
import code.name.monkey.retromusic.App
|
||||||
|
import code.name.monkey.retromusic.R
|
||||||
import code.name.monkey.retromusic.extensions.showToast
|
import code.name.monkey.retromusic.extensions.showToast
|
||||||
import code.name.monkey.retromusic.glide.GlideApp
|
import code.name.monkey.retromusic.glide.GlideApp
|
||||||
import code.name.monkey.retromusic.model.Artist
|
import code.name.monkey.retromusic.model.Artist
|
||||||
|
@ -56,7 +57,7 @@ class CustomArtistImageUtil private constructor(context: Context) {
|
||||||
saveImage(context, artist, it)
|
saveImage(context, artist, it)
|
||||||
}
|
}
|
||||||
.onFailure {
|
.onFailure {
|
||||||
context.showToast("Load Failed")
|
context.showToast(R.string.error_load_failed)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -67,12 +67,12 @@ object PreferenceUtil {
|
||||||
}
|
}
|
||||||
|
|
||||||
fun registerOnSharedPreferenceChangedListener(
|
fun registerOnSharedPreferenceChangedListener(
|
||||||
listener: OnSharedPreferenceChangeListener
|
listener: OnSharedPreferenceChangeListener,
|
||||||
) = sharedPreferences.registerOnSharedPreferenceChangeListener(listener)
|
) = sharedPreferences.registerOnSharedPreferenceChangeListener(listener)
|
||||||
|
|
||||||
|
|
||||||
fun unregisterOnSharedPreferenceChangedListener(
|
fun unregisterOnSharedPreferenceChangedListener(
|
||||||
changeListener: OnSharedPreferenceChangeListener
|
changeListener: OnSharedPreferenceChangeListener,
|
||||||
) = sharedPreferences.unregisterOnSharedPreferenceChangeListener(changeListener)
|
) = sharedPreferences.unregisterOnSharedPreferenceChangeListener(changeListener)
|
||||||
|
|
||||||
|
|
||||||
|
@ -394,7 +394,7 @@ object PreferenceUtil {
|
||||||
val filterLength get() = sharedPreferences.getInt(FILTER_SONG, 20)
|
val filterLength get() = sharedPreferences.getInt(FILTER_SONG, 20)
|
||||||
|
|
||||||
var lastVersion
|
var lastVersion
|
||||||
// This was stored as an integer before now it's a long, so avoid a ClassCastException
|
// This was stored as an integer before now it's a long, so avoid a ClassCastException
|
||||||
get() = try {
|
get() = try {
|
||||||
sharedPreferences.getLong(LAST_CHANGELOG_VERSION, 0)
|
sharedPreferences.getLong(LAST_CHANGELOG_VERSION, 0)
|
||||||
} catch (e: ClassCastException) {
|
} catch (e: ClassCastException) {
|
||||||
|
@ -725,6 +725,9 @@ object PreferenceUtil {
|
||||||
|
|
||||||
val swipeAnywhereToChangeSong
|
val swipeAnywhereToChangeSong
|
||||||
get() = sharedPreferences.getBoolean(SWIPE_ANYWHERE_NOW_PLAYING, true)
|
get() = sharedPreferences.getBoolean(SWIPE_ANYWHERE_NOW_PLAYING, true)
|
||||||
|
|
||||||
|
val swipeDownToDismiss
|
||||||
|
get() = sharedPreferences.getBoolean(SWIPE_DOWN_DISMISS, true)
|
||||||
}
|
}
|
||||||
|
|
||||||
enum class LyricsType {
|
enum class LyricsType {
|
||||||
|
|
|
@ -27,10 +27,10 @@ import code.name.monkey.retromusic.model.Song
|
||||||
import code.name.monkey.retromusic.util.MusicUtil.getSongFileUri
|
import code.name.monkey.retromusic.util.MusicUtil.getSongFileUri
|
||||||
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
||||||
|
|
||||||
class RingtoneManager(val context: Context) {
|
object RingtoneManager {
|
||||||
fun setRingtone(song: Song) {
|
fun setRingtone(context: Context, song: Song) {
|
||||||
val resolver = context.contentResolver
|
|
||||||
val uri = getSongFileUri(song.id)
|
val uri = getSongFileUri(song.id)
|
||||||
|
val resolver = context.contentResolver
|
||||||
|
|
||||||
try {
|
try {
|
||||||
val cursor = resolver.query(
|
val cursor = resolver.query(
|
||||||
|
@ -52,28 +52,25 @@ class RingtoneManager(val context: Context) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
companion object {
|
fun requiresDialog(context: Context): Boolean {
|
||||||
|
if (VersionUtils.hasMarshmallow()) {
|
||||||
fun requiresDialog(context: Context): Boolean {
|
if (!Settings.System.canWrite(context)) {
|
||||||
if (VersionUtils.hasMarshmallow()) {
|
return true
|
||||||
if (!Settings.System.canWrite(context)) {
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
return false
|
|
||||||
}
|
}
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
|
||||||
fun getDialog(context: Context) {
|
fun showDialog(context: Context) {
|
||||||
return MaterialAlertDialogBuilder(context, R.style.MaterialAlertDialogTheme)
|
return MaterialAlertDialogBuilder(context, R.style.MaterialAlertDialogTheme)
|
||||||
.setTitle(R.string.dialog_title_set_ringtone)
|
.setTitle(R.string.dialog_title_set_ringtone)
|
||||||
.setMessage(R.string.dialog_message_set_ringtone)
|
.setMessage(R.string.dialog_message_set_ringtone)
|
||||||
.setPositiveButton(android.R.string.ok) { _, _ ->
|
.setPositiveButton(android.R.string.ok) { _, _ ->
|
||||||
val intent = Intent(Settings.ACTION_MANAGE_WRITE_SETTINGS)
|
val intent = Intent(Settings.ACTION_MANAGE_WRITE_SETTINGS)
|
||||||
intent.data = ("package:" + context.applicationContext.packageName).toUri()
|
intent.data = ("package:" + context.applicationContext.packageName).toUri()
|
||||||
context.startActivity(intent)
|
context.startActivity(intent)
|
||||||
}
|
}
|
||||||
.setNegativeButton(android.R.string.cancel, null)
|
.setNegativeButton(android.R.string.cancel, null)
|
||||||
.create().show()
|
.create().show()
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -1,31 +1,40 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
android:id="@+id/container_all"
|
android:id="@+id/container_all"
|
||||||
android:layout_width="fill_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
android:paddingTop="0dp">
|
android:paddingTop="0dp">
|
||||||
|
|
||||||
<RelativeLayout
|
<RelativeLayout
|
||||||
android:id="@+id/container_current"
|
android:id="@+id/container_current"
|
||||||
android:layout_width="fill_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="@dimen/cast_mini_controller_icon_height">
|
android:layout_height="@dimen/cast_mini_controller_height">
|
||||||
|
|
||||||
<View
|
<View
|
||||||
android:id="@+id/center"
|
android:id="@+id/center"
|
||||||
android:layout_width="fill_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="1dp"
|
android:layout_height="1dp"
|
||||||
android:layout_centerVertical="true"
|
android:layout_centerVertical="true"
|
||||||
android:visibility="invisible" />
|
android:visibility="invisible" />
|
||||||
|
|
||||||
<ImageView
|
<com.google.android.material.card.MaterialCardView
|
||||||
android:id="@+id/icon_view"
|
android:id="@+id/icon_container"
|
||||||
android:layout_width="@dimen/cast_mini_controller_icon_width"
|
android:layout_width="@dimen/cast_mini_controller_image_size"
|
||||||
android:layout_height="@dimen/cast_mini_controller_icon_height"
|
android:layout_height="@dimen/cast_mini_controller_image_size"
|
||||||
android:layout_alignParentStart="true"
|
android:layout_margin="8dp"
|
||||||
android:layout_alignParentLeft="true"
|
app:cardCornerRadius="10dp">
|
||||||
android:scaleType="centerCrop"
|
|
||||||
android:src="@drawable/default_audio_art" />
|
<ImageView
|
||||||
|
android:id="@+id/icon_view"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_alignParentStart="true"
|
||||||
|
android:scaleType="centerCrop"
|
||||||
|
android:src="@drawable/default_audio_art" />
|
||||||
|
</com.google.android.material.card.MaterialCardView>
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/button_0"
|
android:id="@+id/button_0"
|
||||||
|
@ -33,9 +42,7 @@
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_centerVertical="true"
|
android:layout_centerVertical="true"
|
||||||
android:layout_marginEnd="@dimen/cast_mini_controller_control_button_margin"
|
android:layout_marginEnd="@dimen/cast_mini_controller_control_button_margin"
|
||||||
android:layout_marginRight="@dimen/cast_mini_controller_control_button_margin"
|
android:layout_toStartOf="@+id/button_1" />
|
||||||
android:layout_toStartOf="@+id/button_1"
|
|
||||||
android:layout_toLeftOf="@+id/button_1" />
|
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/button_1"
|
android:id="@+id/button_1"
|
||||||
|
@ -43,52 +50,40 @@
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_centerVertical="true"
|
android:layout_centerVertical="true"
|
||||||
android:layout_marginEnd="@dimen/cast_mini_controller_control_button_margin"
|
android:layout_marginEnd="@dimen/cast_mini_controller_control_button_margin"
|
||||||
android:layout_marginRight="@dimen/cast_mini_controller_control_button_margin"
|
android:layout_toStartOf="@+id/button_2" />
|
||||||
android:layout_toStartOf="@+id/button_2"
|
|
||||||
android:layout_toLeftOf="@+id/button_2" />
|
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/button_2"
|
android:id="@+id/button_2"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_alignParentEnd="true"
|
android:layout_alignParentEnd="true"
|
||||||
android:layout_alignParentRight="true"
|
|
||||||
android:layout_centerVertical="true"
|
android:layout_centerVertical="true"
|
||||||
android:layout_marginEnd="8dp"
|
android:layout_marginEnd="8dp" />
|
||||||
android:layout_marginRight="8dp" />
|
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/title_view"
|
android:id="@+id/title_view"
|
||||||
android:layout_width="fill_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_above="@+id/center"
|
android:layout_above="@+id/center"
|
||||||
android:layout_marginStart="15dp"
|
android:layout_marginStart="15dp"
|
||||||
android:layout_marginLeft="15dp"
|
|
||||||
android:layout_marginEnd="8dp"
|
android:layout_marginEnd="8dp"
|
||||||
android:layout_marginRight="8dp"
|
|
||||||
android:layout_marginBottom="-3dp"
|
android:layout_marginBottom="-3dp"
|
||||||
android:layout_toStartOf="@+id/button_0"
|
android:layout_toStartOf="@+id/button_0"
|
||||||
android:layout_toLeftOf="@+id/button_0"
|
android:layout_toEndOf="@+id/icon_container"
|
||||||
android:layout_toEndOf="@+id/icon_view"
|
|
||||||
android:layout_toRightOf="@+id/icon_view"
|
|
||||||
android:ellipsize="end"
|
android:ellipsize="end"
|
||||||
android:maxLines="1"
|
android:maxLines="1"
|
||||||
android:textAppearance="?attr/castTitleTextAppearance" />
|
android:textAppearance="?attr/castTitleTextAppearance" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/subtitle_view"
|
android:id="@+id/subtitle_view"
|
||||||
android:layout_width="fill_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_below="@+id/center"
|
android:layout_below="@+id/center"
|
||||||
android:layout_alignStart="@+id/title_view"
|
android:layout_alignStart="@+id/title_view"
|
||||||
android:layout_alignLeft="@+id/title_view"
|
|
||||||
android:layout_alignEnd="@+id/title_view"
|
android:layout_alignEnd="@+id/title_view"
|
||||||
android:layout_alignRight="@+id/title_view"
|
|
||||||
android:layout_marginTop="3dp"
|
android:layout_marginTop="3dp"
|
||||||
android:layout_toStartOf="@+id/button_0"
|
android:layout_toStartOf="@+id/button_0"
|
||||||
android:layout_toLeftOf="@+id/button_0"
|
android:layout_toEndOf="@+id/icon_container"
|
||||||
android:layout_toEndOf="@+id/icon_view"
|
|
||||||
android:layout_toRightOf="@+id/icon_view"
|
|
||||||
android:ellipsize="end"
|
android:ellipsize="end"
|
||||||
android:maxLines="1"
|
android:maxLines="1"
|
||||||
android:textAppearance="?attr/castSubtitleTextAppearance" />
|
android:textAppearance="?attr/castSubtitleTextAppearance" />
|
||||||
|
@ -97,11 +92,11 @@
|
||||||
<ProgressBar
|
<ProgressBar
|
||||||
android:id="@+id/progressBar"
|
android:id="@+id/progressBar"
|
||||||
style="@android:style/Widget.ProgressBar.Horizontal"
|
style="@android:style/Widget.ProgressBar.Horizontal"
|
||||||
android:layout_width="fill_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="5dp"
|
android:layout_height="5dp"
|
||||||
android:layout_alignParentTop="true"
|
android:layout_alignParentTop="true"
|
||||||
android:layoutDirection="ltr"
|
android:layoutDirection="ltr"
|
||||||
android:progressDrawable="@drawable/cast_mini_controller_progress_drawable" />
|
android:progressDrawable="@drawable/cast_mini_controller_progress_drawable" />
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
|
@ -53,51 +53,54 @@
|
||||||
tools:ignore="RtlHardcoded,RtlSymmetry"
|
tools:ignore="RtlHardcoded,RtlSymmetry"
|
||||||
tools:text="@tools:sample/date/hhmmss" />
|
tools:text="@tools:sample/date/hhmmss" />
|
||||||
|
|
||||||
<com.google.android.material.textview.MaterialTextView
|
<LinearLayout
|
||||||
android:id="@+id/title"
|
android:id="@+id/text_container"
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_gravity="center"
|
android:orientation="vertical"
|
||||||
android:ellipsize="marquee"
|
|
||||||
android:focusable="true"
|
|
||||||
android:freezesText="true"
|
|
||||||
android:gravity="center"
|
|
||||||
android:marqueeRepeatLimit="marquee_forever"
|
|
||||||
android:paddingHorizontal="16dp"
|
|
||||||
android:scrollHorizontally="true"
|
|
||||||
android:singleLine="true"
|
|
||||||
android:textAppearance="@style/TextViewHeadline6"
|
|
||||||
android:textColor="?android:attr/textColorPrimary"
|
|
||||||
android:textStyle="bold"
|
|
||||||
app:layout_constraintBottom_toTopOf="@+id/playPauseCard"
|
app:layout_constraintBottom_toTopOf="@+id/playPauseCard"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/progressSlider"
|
app:layout_constraintTop_toBottomOf="@+id/progressSlider">
|
||||||
app:layout_constraintVertical_bias="0.3"
|
|
||||||
tools:text="@tools:sample/lorem/random" />
|
|
||||||
|
|
||||||
<com.google.android.material.textview.MaterialTextView
|
<com.google.android.material.textview.MaterialTextView
|
||||||
android:id="@+id/text"
|
android:id="@+id/title"
|
||||||
android:layout_width="0dp"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="8dp"
|
android:layout_gravity="center"
|
||||||
android:ellipsize="marquee"
|
android:ellipsize="marquee"
|
||||||
android:focusable="true"
|
android:focusable="true"
|
||||||
android:focusableInTouchMode="true"
|
android:freezesText="true"
|
||||||
android:freezesText="true"
|
android:gravity="center"
|
||||||
android:gravity="center"
|
android:marqueeRepeatLimit="marquee_forever"
|
||||||
android:marqueeRepeatLimit="marquee_forever"
|
android:paddingHorizontal="16dp"
|
||||||
android:paddingHorizontal="16dp"
|
android:scrollHorizontally="true"
|
||||||
android:paddingVertical="8dp"
|
android:singleLine="true"
|
||||||
android:scrollHorizontally="true"
|
android:textAppearance="@style/TextViewHeadline6"
|
||||||
android:singleLine="true"
|
android:textColor="?android:attr/textColorPrimary"
|
||||||
android:textAppearance="@style/TextViewBody1"
|
android:textStyle="bold"
|
||||||
android:textColor="?android:attr/textColorSecondary"
|
tools:text="@tools:sample/lorem/random" />
|
||||||
app:layout_constrainedWidth="true"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
<com.google.android.material.textview.MaterialTextView
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
android:id="@+id/text"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/title"
|
android:layout_width="match_parent"
|
||||||
tools:text="@tools:sample/full_names" />
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="8dp"
|
||||||
|
android:ellipsize="marquee"
|
||||||
|
android:focusable="true"
|
||||||
|
android:focusableInTouchMode="true"
|
||||||
|
android:freezesText="true"
|
||||||
|
android:gravity="center"
|
||||||
|
android:marqueeRepeatLimit="marquee_forever"
|
||||||
|
android:paddingHorizontal="16dp"
|
||||||
|
android:paddingVertical="8dp"
|
||||||
|
android:scrollHorizontally="true"
|
||||||
|
android:singleLine="true"
|
||||||
|
android:textAppearance="@style/TextViewBody1"
|
||||||
|
android:textColor="?android:attr/textColorSecondary"
|
||||||
|
app:layout_constrainedWidth="true"
|
||||||
|
tools:text="@tools:sample/full_names" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
<com.google.android.material.textview.MaterialTextView
|
<com.google.android.material.textview.MaterialTextView
|
||||||
android:id="@+id/songInfo"
|
android:id="@+id/songInfo"
|
||||||
|
@ -111,7 +114,9 @@
|
||||||
android:textSize="12sp"
|
android:textSize="12sp"
|
||||||
app:layout_constraintBottom_toTopOf="@+id/volumeFragmentContainer"
|
app:layout_constraintBottom_toTopOf="@+id/volumeFragmentContainer"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintHorizontal_bias="0.5"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toBottomOf="@+id/repeatButton"
|
||||||
tools:text="@tools:sample/full_names" />
|
tools:text="@tools:sample/full_names" />
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatImageButton
|
<androidx.appcompat.widget.AppCompatImageButton
|
||||||
|
@ -138,8 +143,9 @@
|
||||||
app:cardCornerRadius="40dp"
|
app:cardCornerRadius="40dp"
|
||||||
app:layout_constraintBottom_toTopOf="@+id/repeatButton"
|
app:layout_constraintBottom_toTopOf="@+id/repeatButton"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintHorizontal_bias="0.5"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/text"
|
app:layout_constraintTop_toBottomOf="@+id/text_container"
|
||||||
tools:tint="@color/md_black_1000">
|
tools:tint="@color/md_black_1000">
|
||||||
|
|
||||||
<ImageButton
|
<ImageButton
|
||||||
|
@ -176,10 +182,10 @@
|
||||||
android:background="@null"
|
android:background="@null"
|
||||||
android:paddingVertical="16dp"
|
android:paddingVertical="16dp"
|
||||||
android:src="@drawable/ic_shuffle"
|
android:src="@drawable/ic_shuffle"
|
||||||
app:layout_constraintBottom_toTopOf="@+id/songInfo"
|
app:layout_constraintBottom_toBottomOf="@+id/repeatButton"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toEndOf="@id/repeatButton"
|
app:layout_constraintStart_toEndOf="@id/repeatButton"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/playPauseCard"
|
app:layout_constraintTop_toTopOf="@+id/repeatButton"
|
||||||
tools:ignore="MissingPrefix"
|
tools:ignore="MissingPrefix"
|
||||||
tools:tint="@color/md_black_1000" />
|
tools:tint="@color/md_black_1000" />
|
||||||
|
|
||||||
|
@ -193,6 +199,7 @@
|
||||||
android:src="@drawable/ic_repeat"
|
android:src="@drawable/ic_repeat"
|
||||||
app:layout_constraintBottom_toTopOf="@+id/songInfo"
|
app:layout_constraintBottom_toTopOf="@+id/songInfo"
|
||||||
app:layout_constraintEnd_toStartOf="@id/shuffleButton"
|
app:layout_constraintEnd_toStartOf="@id/shuffleButton"
|
||||||
|
app:layout_constraintHorizontal_bias="0.5"
|
||||||
app:layout_constraintHorizontal_chainStyle="spread_inside"
|
app:layout_constraintHorizontal_chainStyle="spread_inside"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/playPauseCard"
|
app:layout_constraintTop_toBottomOf="@+id/playPauseCard"
|
||||||
|
|
|
@ -72,4 +72,6 @@
|
||||||
<dimen name="padding_album_cover">16dp</dimen>
|
<dimen name="padding_album_cover">16dp</dimen>
|
||||||
|
|
||||||
<dimen name="seekbar_padding">16dp</dimen>
|
<dimen name="seekbar_padding">16dp</dimen>
|
||||||
|
<dimen name="cast_mini_controller_height">64dp</dimen>
|
||||||
|
<dimen name="cast_mini_controller_image_size">48dp</dimen>
|
||||||
</resources>
|
</resources>
|
||||||
|
|
|
@ -86,7 +86,9 @@
|
||||||
<string name="audio_settings_summary">Change the sound settings and adjust the equalizer controls</string>
|
<string name="audio_settings_summary">Change the sound settings and adjust the equalizer controls</string>
|
||||||
<string name="auto">Auto</string>
|
<string name="auto">Auto</string>
|
||||||
<string name="backup_restore_settings_summary">Backup and restore your settings, playlists</string>
|
<string name="backup_restore_settings_summary">Backup and restore your settings, playlists</string>
|
||||||
<string name="backup_restore_title"><![CDATA[Backup & Restore]]></string>
|
<string name="backup_restore_title">
|
||||||
|
<![CDATA[Backup & Restore]]>
|
||||||
|
</string>
|
||||||
<string name="backup_title">Backups</string>
|
<string name="backup_title">Backups</string>
|
||||||
<string name="biography">Biography</string>
|
<string name="biography">Biography</string>
|
||||||
<string name="black_theme_name">Just Black</string>
|
<string name="black_theme_name">Just Black</string>
|
||||||
|
@ -171,9 +173,14 @@
|
||||||
<string name="edit_synced_lyrics">Edit Synced Lyrics</string>
|
<string name="edit_synced_lyrics">Edit Synced Lyrics</string>
|
||||||
<string name="empty">Empty</string>
|
<string name="empty">Empty</string>
|
||||||
<string name="equalizer">Equalizer</string>
|
<string name="equalizer">Equalizer</string>
|
||||||
|
<string name="error_create_backup">Couldn\u2019t create backup</string>
|
||||||
|
<string name="error_delete_backup">Couldn\u2019t delete backup</string>
|
||||||
|
<string name="error_empty_name">Your name can\'t be empty!</string>
|
||||||
|
<string name="error_load_failed">Load failed</string>
|
||||||
<string name="expanded">Expanded</string>
|
<string name="expanded">Expanded</string>
|
||||||
<string name="faq">FAQ</string>
|
<string name="faq">FAQ</string>
|
||||||
<string name="favorites">Favorites</string>
|
<string name="favorites">Favorites</string>
|
||||||
|
<string name="file_already_exists">File already exists</string>
|
||||||
<string name="finish_last_song">Finish last song</string>
|
<string name="finish_last_song">Finish last song</string>
|
||||||
<string name="fit">Fit</string>
|
<string name="fit">Fit</string>
|
||||||
<string name="flat">Flat</string>
|
<string name="flat">Flat</string>
|
||||||
|
@ -237,9 +244,15 @@
|
||||||
<string name="lyrics">Lyrics</string>
|
<string name="lyrics">Lyrics</string>
|
||||||
<string name="made_with_love">Made with ❤️ in India</string>
|
<string name="made_with_love">Made with ❤️ in India</string>
|
||||||
<string name="material">Material</string>
|
<string name="material">Material</string>
|
||||||
|
<string name="md3" translatable="false">MD3</string>
|
||||||
<string name="md_error_label">Error</string>
|
<string name="md_error_label">Error</string>
|
||||||
<string name="md_storage_perm_error">Permission error</string>
|
<string name="md_storage_perm_error">Permission error</string>
|
||||||
<string name="md3" translatable="false">MD3</string>
|
<string name="message_backup_create_success">Backup created successfully.</string>
|
||||||
|
<string name="message_limit_tabs">Not more than 5 items</string>
|
||||||
|
<string name="message_pro_feature">%s is a Pro feature.</string>
|
||||||
|
<string name="message_restore_success">Restore completed successfully.</string>
|
||||||
|
<string name="message_updated">Updated</string>
|
||||||
|
<string name="message_welcome"><![CDATA[Hello there! <br>Welcome to %s]]></string>
|
||||||
<string name="my_name">Name</string>
|
<string name="my_name">Name</string>
|
||||||
<string name="my_top_tracks">Most played</string>
|
<string name="my_top_tracks">Most played</string>
|
||||||
<string name="never">Never</string>
|
<string name="never">Never</string>
|
||||||
|
@ -342,6 +355,7 @@
|
||||||
<string name="pref_summary_ignore_media_store_artwork">Can increase the album cover quality, but causes slower image loading times. Only enable this if you have problems with low resolution artworks</string>
|
<string name="pref_summary_ignore_media_store_artwork">Can increase the album cover quality, but causes slower image loading times. Only enable this if you have problems with low resolution artworks</string>
|
||||||
<string name="pref_summary_library_categories">Configure visibility and order of library categories.</string>
|
<string name="pref_summary_library_categories">Configure visibility and order of library categories.</string>
|
||||||
<string name="pref_summary_lock_screen">Use Retro Music\'s custom lockscreen controls</string>
|
<string name="pref_summary_lock_screen">Use Retro Music\'s custom lockscreen controls</string>
|
||||||
|
<string name="pref_summary_manage_audio_focus">Always play audio in background regardless of anything else being played</string>
|
||||||
<string name="pref_summary_open_source_licences">License details for open source software</string>
|
<string name="pref_summary_open_source_licences">License details for open source software</string>
|
||||||
<string name="pref_summary_pause_history">When enabled, newly played songs won\'t show in history</string>
|
<string name="pref_summary_pause_history">When enabled, newly played songs won\'t show in history</string>
|
||||||
<string name="pref_summary_remember_tab">Navigate to the last used tab on start</string>
|
<string name="pref_summary_remember_tab">Navigate to the last used tab on start</string>
|
||||||
|
@ -354,7 +368,6 @@
|
||||||
<string name="pref_summary_toggle_volume">If enough space is available, show volume controls in the now playing screen</string>
|
<string name="pref_summary_toggle_volume">If enough space is available, show volume controls in the now playing screen</string>
|
||||||
<string name="pref_summary_wallpaper_accent">Extract accent color from wallpaper</string>
|
<string name="pref_summary_wallpaper_accent">Extract accent color from wallpaper</string>
|
||||||
<string name="pref_summary_whitelist">Only show music from /Music Folder</string>
|
<string name="pref_summary_whitelist">Only show music from /Music Folder</string>
|
||||||
<string name="pref_summary_manage_audio_focus">Always play audio in background regardless of anything else being played</string>
|
|
||||||
<string name="pref_title_album_art_on_lockscreen">Show album cover</string>
|
<string name="pref_title_album_art_on_lockscreen">Show album cover</string>
|
||||||
<string name="pref_title_album_artists_only">Navigate by Album Artist</string>
|
<string name="pref_title_album_artists_only">Navigate by Album Artist</string>
|
||||||
<string name="pref_title_album_cover_style">Album cover theme</string>
|
<string name="pref_title_album_cover_style">Album cover theme</string>
|
||||||
|
@ -387,6 +400,7 @@
|
||||||
<string name="pref_title_lock_screen">Fullscreen controls</string>
|
<string name="pref_title_lock_screen">Fullscreen controls</string>
|
||||||
<string name="pref_title_lyrics_screen_on">Keep screen on when showing lyrics</string>
|
<string name="pref_title_lyrics_screen_on">Keep screen on when showing lyrics</string>
|
||||||
<string name="pref_title_lyrics_type">Lyrics type</string>
|
<string name="pref_title_lyrics_type">Lyrics type</string>
|
||||||
|
<string name="pref_title_manage_audio_focus">Always play</string>
|
||||||
<string name="pref_title_now_playing_screen_appearance">Now playing theme</string>
|
<string name="pref_title_now_playing_screen_appearance">Now playing theme</string>
|
||||||
<string name="pref_title_open_source_licences">Open source licences</string>
|
<string name="pref_title_open_source_licences">Open source licences</string>
|
||||||
<string name="pref_title_pause_history">Pause history</string>
|
<string name="pref_title_pause_history">Pause history</string>
|
||||||
|
@ -402,7 +416,6 @@
|
||||||
<string name="pref_title_toggle_volume">Volume controls</string>
|
<string name="pref_title_toggle_volume">Volume controls</string>
|
||||||
<string name="pref_title_wallpaper_accent">Wallpaper accent color</string>
|
<string name="pref_title_wallpaper_accent">Wallpaper accent color</string>
|
||||||
<string name="pref_title_whitelist">Whitelist music</string>
|
<string name="pref_title_whitelist">Whitelist music</string>
|
||||||
<string name="pref_title_manage_audio_focus">Always play</string>
|
|
||||||
<string name="pro">Pro</string>
|
<string name="pro">Pro</string>
|
||||||
<string name="pro_summary">Black theme, Now playing themes, Carousel effect and more..</string>
|
<string name="pro_summary">Black theme, Now playing themes, Carousel effect and more..</string>
|
||||||
<string name="profile">Profile</string>
|
<string name="profile">Profile</string>
|
||||||
|
@ -540,4 +553,6 @@
|
||||||
<string name="you_have_to_select_at_least_one_category">You have to select at least one category.</string>
|
<string name="you_have_to_select_at_least_one_category">You have to select at least one category.</string>
|
||||||
<string name="you_will_be_forwarded_to_the_issue_tracker_website">You will be forwarded to the issue tracker website.</string>
|
<string name="you_will_be_forwarded_to_the_issue_tracker_website">You will be forwarded to the issue tracker website.</string>
|
||||||
<string name="your_account_data_is_only_used_for_authentication">Your account data is only used for authentication.</string>
|
<string name="your_account_data_is_only_used_for_authentication">Your account data is only used for authentication.</string>
|
||||||
|
<string name="pref_summary_swipe_to_dismiss">Swipe down to dismiss mini player</string>
|
||||||
|
<string name="pref_title_swipe_to_dismiss">Dismiss with swipe down</string>
|
||||||
</resources>
|
</resources>
|
||||||
|
|
|
@ -80,6 +80,13 @@
|
||||||
android:layout="@layout/preference_category_title"
|
android:layout="@layout/preference_category_title"
|
||||||
android:title="@string/pref_header_controls">
|
android:title="@string/pref_header_controls">
|
||||||
|
|
||||||
|
<code.name.monkey.appthemehelper.common.prefs.supportv7.ATESwitchPreference
|
||||||
|
android:layout="@layout/list_item_view_switch"
|
||||||
|
app:defaultValue="false"
|
||||||
|
app:key="swipe_to_dismiss"
|
||||||
|
app:summary="@string/pref_summary_swipe_to_dismiss"
|
||||||
|
app:title="@string/pref_title_swipe_to_dismiss" />
|
||||||
|
|
||||||
<code.name.monkey.appthemehelper.common.prefs.supportv7.ATESwitchPreference
|
<code.name.monkey.appthemehelper.common.prefs.supportv7.ATESwitchPreference
|
||||||
android:layout="@layout/list_item_view_switch"
|
android:layout="@layout/list_item_view_switch"
|
||||||
app:defaultValue="false"
|
app:defaultValue="false"
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
buildscript {
|
buildscript {
|
||||||
ext {
|
ext {
|
||||||
kotlin_version = '1.6.21'
|
kotlin_version = '1.6.21'
|
||||||
navigation_version = '2.5.0-beta01'
|
navigation_version = '2.5.0-rc01'
|
||||||
mdc_version = '1.6.0'
|
mdc_version = '1.6.0'
|
||||||
preference_version = '1.2.0'
|
preference_version = '1.2.0'
|
||||||
appcompat_version = '1.4.1'
|
appcompat_version = '1.4.1'
|
||||||
|
@ -14,7 +14,7 @@ buildscript {
|
||||||
google()
|
google()
|
||||||
}
|
}
|
||||||
dependencies {
|
dependencies {
|
||||||
classpath 'com.android.tools.build:gradle:7.1.3'
|
classpath 'com.android.tools.build:gradle:7.2.0'
|
||||||
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
|
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
|
||||||
classpath "androidx.navigation:navigation-safe-args-gradle-plugin:$navigation_version"
|
classpath "androidx.navigation:navigation-safe-args-gradle-plugin:$navigation_version"
|
||||||
}
|
}
|
||||||
|
|
2
gradle/wrapper/gradle-wrapper.properties
vendored
2
gradle/wrapper/gradle-wrapper.properties
vendored
|
@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME
|
||||||
distributionPath=wrapper/dists
|
distributionPath=wrapper/dists
|
||||||
zipStoreBase=GRADLE_USER_HOME
|
zipStoreBase=GRADLE_USER_HOME
|
||||||
zipStorePath=wrapper/dists
|
zipStorePath=wrapper/dists
|
||||||
distributionUrl=https\://services.gradle.org/distributions/gradle-7.2-all.zip
|
distributionUrl=https\://services.gradle.org/distributions/gradle-7.3.3-all.zip
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue