From 654ec3fe66913d35fb784a14d1b21e8e0d28cd48 Mon Sep 17 00:00:00 2001 From: Tommaso Berlose Date: Fri, 8 May 2020 15:10:19 +0200 Subject: [PATCH] Add current song --- app/src/main/AndroidManifest.xml | 6 + .../anotherwidget/global/Preferences.kt | 11 ++ .../anotherwidget/helpers/IntentHelper.kt | 18 +++ .../helpers/MediaPlayerHelper.kt | 88 +++++++++++ .../anotherwidget/helpers/WeatherHelper.kt | 1 + .../anotherwidget/helpers/WidgetHelper.kt | 9 ++ .../receivers/MusicNotificationListener.kt | 37 +++++ .../ui/adapters/ViewPagerAdapter.kt | 3 +- .../ui/fragments/MainFragment.kt | 37 +++-- .../ui/fragments/MusicTabFragment.kt | 144 ++++++++++++++++++ .../ui/fragments/SettingsFragment.kt | 2 + .../ui/viewmodels/MainViewModel.kt | 4 + .../anotherwidget/ui/widgets/MainWidget.kt | 80 +++++++++- .../res/drawable-hdpi/round_music_note.png | Bin 0 -> 405 bytes .../round_music_note_black_18.png | Bin 0 -> 218 bytes .../round_music_note_black_24.png | Bin 0 -> 248 bytes .../round_music_note_black_36.png | Bin 0 -> 338 bytes .../res/drawable-hdpi/round_queue_music.png | Bin 0 -> 360 bytes .../round_queue_music_black_18.png | Bin 0 -> 254 bytes .../round_queue_music_black_24.png | Bin 0 -> 257 bytes .../round_queue_music_black_48.png | Bin 0 -> 412 bytes .../res/drawable-mdpi/round_music_note.png | Bin 0 -> 286 bytes .../round_music_note_black_18.png | Bin 0 -> 175 bytes .../round_music_note_black_24.png | Bin 0 -> 181 bytes .../round_music_note_black_36.png | Bin 0 -> 248 bytes .../res/drawable-mdpi/round_queue_music.png | Bin 0 -> 257 bytes .../round_queue_music_black_18.png | Bin 0 -> 168 bytes .../round_queue_music_black_24.png | Bin 0 -> 165 bytes .../round_queue_music_black_48.png | Bin 0 -> 283 bytes .../res/drawable-xhdpi/round_music_note.png | Bin 0 -> 525 bytes .../round_music_note_black_18.png | Bin 0 -> 248 bytes .../round_music_note_black_24.png | Bin 0 -> 286 bytes .../round_music_note_black_36.png | Bin 0 -> 405 bytes .../res/drawable-xhdpi/round_queue_music.png | Bin 0 -> 412 bytes .../round_queue_music_black_18.png | Bin 0 -> 257 bytes .../round_queue_music_black_24.png | Bin 0 -> 283 bytes .../round_queue_music_black_48.png | Bin 0 -> 507 bytes .../res/drawable-xxhdpi/round_music_note.png | Bin 0 -> 774 bytes .../round_music_note_black_18.png | Bin 0 -> 338 bytes .../round_music_note_black_24.png | Bin 0 -> 405 bytes .../round_music_note_black_36.png | Bin 0 -> 588 bytes .../res/drawable-xxhdpi/round_queue_music.png | Bin 0 -> 618 bytes .../round_queue_music_black_18.png | Bin 0 -> 360 bytes .../round_queue_music_black_24.png | Bin 0 -> 412 bytes .../round_queue_music_black_48.png | Bin 0 -> 789 bytes .../res/drawable-xxxhdpi/round_music_note.png | Bin 0 -> 943 bytes .../round_music_note_black_18.png | Bin 0 -> 405 bytes .../round_music_note_black_24.png | Bin 0 -> 525 bytes .../round_music_note_black_36.png | Bin 0 -> 774 bytes .../drawable-xxxhdpi/round_queue_music.png | Bin 0 -> 789 bytes .../round_queue_music_black_18.png | Bin 0 -> 412 bytes .../round_queue_music_black_24.png | Bin 0 -> 507 bytes .../round_queue_music_black_48.png | Bin 0 -> 982 bytes .../main/res/drawable/round_music_note_24.xml | 10 ++ .../res/drawable/round_queue_music_24.xml | 10 ++ .../res/layout/fragment_music_settings.xml | 125 +++++++++++++++ app/src/main/res/layout/the_widget.xml | 30 ++++ app/src/main/res/layout/the_widget_sans.xml | 4 + app/src/main/res/values-de/strings.xml | 6 + app/src/main/res/values-fr/strings.xml | 6 + app/src/main/res/values-it/strings.xml | 6 + app/src/main/res/values/strings.xml | 6 + .../tmp/debug/dex-renamer-state.txt | 2 +- .../tmp/debug/zip-cache/androidResources | Bin 147 -> 147 bytes 64 files changed, 623 insertions(+), 22 deletions(-) create mode 100644 app/src/main/java/com/tommasoberlose/anotherwidget/helpers/MediaPlayerHelper.kt create mode 100644 app/src/main/java/com/tommasoberlose/anotherwidget/receivers/MusicNotificationListener.kt create mode 100644 app/src/main/java/com/tommasoberlose/anotherwidget/ui/fragments/MusicTabFragment.kt create mode 100644 app/src/main/res/drawable-hdpi/round_music_note.png create mode 100644 app/src/main/res/drawable-hdpi/round_music_note_black_18.png create mode 100644 app/src/main/res/drawable-hdpi/round_music_note_black_24.png create mode 100644 app/src/main/res/drawable-hdpi/round_music_note_black_36.png create mode 100644 app/src/main/res/drawable-hdpi/round_queue_music.png create mode 100644 app/src/main/res/drawable-hdpi/round_queue_music_black_18.png create mode 100644 app/src/main/res/drawable-hdpi/round_queue_music_black_24.png create mode 100644 app/src/main/res/drawable-hdpi/round_queue_music_black_48.png create mode 100644 app/src/main/res/drawable-mdpi/round_music_note.png create mode 100644 app/src/main/res/drawable-mdpi/round_music_note_black_18.png create mode 100644 app/src/main/res/drawable-mdpi/round_music_note_black_24.png create mode 100644 app/src/main/res/drawable-mdpi/round_music_note_black_36.png create mode 100644 app/src/main/res/drawable-mdpi/round_queue_music.png create mode 100644 app/src/main/res/drawable-mdpi/round_queue_music_black_18.png create mode 100644 app/src/main/res/drawable-mdpi/round_queue_music_black_24.png create mode 100644 app/src/main/res/drawable-mdpi/round_queue_music_black_48.png create mode 100644 app/src/main/res/drawable-xhdpi/round_music_note.png create mode 100644 app/src/main/res/drawable-xhdpi/round_music_note_black_18.png create mode 100644 app/src/main/res/drawable-xhdpi/round_music_note_black_24.png create mode 100644 app/src/main/res/drawable-xhdpi/round_music_note_black_36.png create mode 100644 app/src/main/res/drawable-xhdpi/round_queue_music.png create mode 100644 app/src/main/res/drawable-xhdpi/round_queue_music_black_18.png create mode 100644 app/src/main/res/drawable-xhdpi/round_queue_music_black_24.png create mode 100644 app/src/main/res/drawable-xhdpi/round_queue_music_black_48.png create mode 100644 app/src/main/res/drawable-xxhdpi/round_music_note.png create mode 100644 app/src/main/res/drawable-xxhdpi/round_music_note_black_18.png create mode 100644 app/src/main/res/drawable-xxhdpi/round_music_note_black_24.png create mode 100644 app/src/main/res/drawable-xxhdpi/round_music_note_black_36.png create mode 100644 app/src/main/res/drawable-xxhdpi/round_queue_music.png create mode 100644 app/src/main/res/drawable-xxhdpi/round_queue_music_black_18.png create mode 100644 app/src/main/res/drawable-xxhdpi/round_queue_music_black_24.png create mode 100644 app/src/main/res/drawable-xxhdpi/round_queue_music_black_48.png create mode 100644 app/src/main/res/drawable-xxxhdpi/round_music_note.png create mode 100644 app/src/main/res/drawable-xxxhdpi/round_music_note_black_18.png create mode 100644 app/src/main/res/drawable-xxxhdpi/round_music_note_black_24.png create mode 100644 app/src/main/res/drawable-xxxhdpi/round_music_note_black_36.png create mode 100644 app/src/main/res/drawable-xxxhdpi/round_queue_music.png create mode 100644 app/src/main/res/drawable-xxxhdpi/round_queue_music_black_18.png create mode 100644 app/src/main/res/drawable-xxxhdpi/round_queue_music_black_24.png create mode 100644 app/src/main/res/drawable-xxxhdpi/round_queue_music_black_48.png create mode 100644 app/src/main/res/drawable/round_music_note_24.xml create mode 100644 app/src/main/res/drawable/round_queue_music_24.xml create mode 100644 app/src/main/res/layout/fragment_music_settings.xml diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index 41a05f7..95c24f6 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -139,6 +139,12 @@ + + + + + \ No newline at end of file diff --git a/app/src/main/java/com/tommasoberlose/anotherwidget/global/Preferences.kt b/app/src/main/java/com/tommasoberlose/anotherwidget/global/Preferences.kt index 12a4dd3..48ddf16 100755 --- a/app/src/main/java/com/tommasoberlose/anotherwidget/global/Preferences.kt +++ b/app/src/main/java/com/tommasoberlose/anotherwidget/global/Preferences.kt @@ -9,6 +9,7 @@ object Preferences : KotprefModel() { var darkThemePreference by intPref(default = MODE_NIGHT_FOLLOW_SYSTEM) + // Calendar and weather var showEvents by booleanPref(key = "PREF_SHOW_EVENTS", default = false) var showWeather by booleanPref(key = "PREF_SHOW_WEATHER", default = false) var weatherIcon by stringPref(key = "PREF_WEATHER_ICON", default = "") @@ -48,6 +49,7 @@ object Preferences : KotprefModel() { var clockTextColor by stringPref(default = "#FFFFFF") var clockTextAlpha by stringPref(default = "FF") + // Global var textMainSize by floatPref(key = "PREF_TEXT_MAIN_SIZE", default = 26f) var textSecondSize by floatPref(key = "PREF_TEXT_SECOND_SIZE", default = 18f) var clockTextSize by floatPref(key = "PREF_TEXT_CLOCK_SIZE", default = 90f) @@ -64,9 +66,18 @@ object Preferences : KotprefModel() { var customFontFile by stringPref(key = "PREF_CUSTOM_FONT_FILE") var showNextEvent by booleanPref(key = "PREF_SHOW_NEXT_EVENT", default = true) + // Settings var showWallpaper by booleanPref(default = true) var showBigClockWarning by booleanPref(default = true) var showWeatherWarning by booleanPref(default = true) var showPreview by booleanPref(default = true) var showXiaomiWarning by booleanPref(default = true) + + // Music + var showMusic by booleanPref(default = false) + var mediaInfoFormat by stringPref(default = "") + var mediaPlayerTitle by stringPref(default = "") + var mediaPlayerAlbum by stringPref(default = "") + var mediaPlayerArtist by stringPref(default = "") + var mediaPlayerPackage by stringPref(default = "") } diff --git a/app/src/main/java/com/tommasoberlose/anotherwidget/helpers/IntentHelper.kt b/app/src/main/java/com/tommasoberlose/anotherwidget/helpers/IntentHelper.kt index c12d429..0822ea1 100644 --- a/app/src/main/java/com/tommasoberlose/anotherwidget/helpers/IntentHelper.kt +++ b/app/src/main/java/com/tommasoberlose/anotherwidget/helpers/IntentHelper.kt @@ -160,4 +160,22 @@ object IntentHelper { } } } + + fun getMusicIntent(context: Context): Intent { + return when (Preferences.mediaPlayerPackage) { + "" -> { + Intent() + } + else -> { + val pm: PackageManager = context.packageManager + try { + pm.getLaunchIntentForPackage(Preferences.mediaPlayerPackage)!!.apply { + addCategory(Intent.CATEGORY_LAUNCHER) + } + } catch (e: Exception) { + Intent() + } + } + } + } } \ No newline at end of file diff --git a/app/src/main/java/com/tommasoberlose/anotherwidget/helpers/MediaPlayerHelper.kt b/app/src/main/java/com/tommasoberlose/anotherwidget/helpers/MediaPlayerHelper.kt new file mode 100644 index 0000000..baf5fc3 --- /dev/null +++ b/app/src/main/java/com/tommasoberlose/anotherwidget/helpers/MediaPlayerHelper.kt @@ -0,0 +1,88 @@ +package com.tommasoberlose.anotherwidget.helpers + +import android.app.Notification +import android.content.ComponentName +import android.content.Context +import android.media.MediaMetadata +import android.media.session.MediaController +import android.media.session.MediaSession +import android.media.session.MediaSessionManager +import android.media.session.PlaybackState +import android.util.Log +import androidx.core.app.NotificationManagerCompat +import com.chibatching.kotpref.bulk +import com.tommasoberlose.anotherwidget.global.Preferences +import com.tommasoberlose.anotherwidget.receivers.MusicNotificationListener +import com.tommasoberlose.anotherwidget.ui.widgets.MainWidget +import java.lang.Exception + +object MediaPlayerHelper { + fun isSomeonePlaying(context: Context) = Preferences.showMusic && NotificationManagerCompat.getEnabledListenerPackages(context).contains(context.packageName) && Preferences.mediaPlayerTitle != "" + + fun getMediaInfo(): String { + return if (Preferences.mediaPlayerArtist == "") { + Preferences.mediaPlayerTitle + } else { + "%s, %s".format(Preferences.mediaPlayerTitle, Preferences.mediaPlayerArtist) + } + } + + fun updatePlayingMediaInfo(context: Context) { + if (NotificationManagerCompat.getEnabledListenerPackages(context).contains(context.packageName)) { + val list = try { + (context.getSystemService(Context.MEDIA_SESSION_SERVICE) as MediaSessionManager).getActiveSessions( + ComponentName(context.packageName, MusicNotificationListener::class.java.name) + ) + } catch (ex: Exception) { + emptyList() + } + + if (list.isNotEmpty()) { + var isSomeonePlaying = false + list.forEach { mc -> + val metadata = mc.metadata + val isPlaying = + mc.playbackState?.state == PlaybackState.STATE_PLAYING || mc.playbackState?.state == PlaybackState.STATE_CONNECTING + + if (isPlaying) { + isSomeonePlaying = true + if (metadata != null) { + Preferences.bulk { + mediaPlayerTitle = + metadata.getText(MediaMetadata.METADATA_KEY_TITLE)?.toString() + ?: "" + mediaPlayerArtist = + metadata.getText(MediaMetadata.METADATA_KEY_ARTIST)?.toString() + ?: "" + mediaPlayerAlbum = + metadata.getText(MediaMetadata.METADATA_KEY_ALBUM)?.toString() + ?: "" + } + } + + Preferences.mediaPlayerPackage = mc.packageName + } + } + + if (!isSomeonePlaying) { + removeMediaInfo() + } + + } else { + removeMediaInfo() + } + } else { + removeMediaInfo() + } + MainWidget.updateWidget(context) + } + + private fun removeMediaInfo() { + Preferences.bulk { + remove(Preferences::mediaPlayerTitle) + remove(Preferences::mediaPlayerArtist) + remove(Preferences::mediaPlayerAlbum) + remove(Preferences::mediaPlayerPackage) + } + } +} \ No newline at end of file diff --git a/app/src/main/java/com/tommasoberlose/anotherwidget/helpers/WeatherHelper.kt b/app/src/main/java/com/tommasoberlose/anotherwidget/helpers/WeatherHelper.kt index 4d0ddcb..7e82590 100644 --- a/app/src/main/java/com/tommasoberlose/anotherwidget/helpers/WeatherHelper.kt +++ b/app/src/main/java/com/tommasoberlose/anotherwidget/helpers/WeatherHelper.kt @@ -5,6 +5,7 @@ import android.content.Context import android.os.Build import com.google.android.gms.location.LocationServices import com.tommasoberlose.anotherwidget.R +import com.tommasoberlose.anotherwidget.db.EventRepository import com.tommasoberlose.anotherwidget.global.Preferences import com.tommasoberlose.anotherwidget.network.WeatherNetworkApi import com.tommasoberlose.anotherwidget.ui.fragments.MainFragment diff --git a/app/src/main/java/com/tommasoberlose/anotherwidget/helpers/WidgetHelper.kt b/app/src/main/java/com/tommasoberlose/anotherwidget/helpers/WidgetHelper.kt index 7e3c854..b4f3f18 100644 --- a/app/src/main/java/com/tommasoberlose/anotherwidget/helpers/WidgetHelper.kt +++ b/app/src/main/java/com/tommasoberlose/anotherwidget/helpers/WidgetHelper.kt @@ -4,6 +4,8 @@ import android.appwidget.AppWidgetManager import android.content.Context import android.content.res.Configuration.ORIENTATION_PORTRAIT import com.google.firebase.crashlytics.FirebaseCrashlytics +import com.tommasoberlose.anotherwidget.db.EventRepository +import com.tommasoberlose.anotherwidget.global.Preferences object WidgetHelper { class WidgetSizeProvider( @@ -51,4 +53,11 @@ object WidgetHelper { width to second * factor } } + + fun showSpecialWeather(context: Context): Boolean { + return EventRepository(context).getEventsCount() == 0 && ( + (Preferences.showNextAlarm && AlarmHelper.getNextAlarm(context) != "") || + (MediaPlayerHelper.isSomeonePlaying(context)) + ) + } } \ No newline at end of file diff --git a/app/src/main/java/com/tommasoberlose/anotherwidget/receivers/MusicNotificationListener.kt b/app/src/main/java/com/tommasoberlose/anotherwidget/receivers/MusicNotificationListener.kt new file mode 100644 index 0000000..8780339 --- /dev/null +++ b/app/src/main/java/com/tommasoberlose/anotherwidget/receivers/MusicNotificationListener.kt @@ -0,0 +1,37 @@ +package com.tommasoberlose.anotherwidget.receivers + +import android.app.Notification +import android.media.MediaMetadata +import android.media.session.MediaController +import android.media.session.MediaSession +import android.media.session.PlaybackState +import android.service.notification.NotificationListenerService +import android.service.notification.StatusBarNotification +import android.util.Log +import com.chibatching.kotpref.bulk +import com.tommasoberlose.anotherwidget.global.Preferences +import com.tommasoberlose.anotherwidget.helpers.MediaPlayerHelper +import com.tommasoberlose.anotherwidget.helpers.WidgetHelper +import com.tommasoberlose.anotherwidget.ui.widgets.MainWidget + + +class MusicNotificationListener : NotificationListenerService() { + override fun onListenerConnected() { + MediaPlayerHelper.updatePlayingMediaInfo(this) + super.onListenerConnected() + } + + override fun onNotificationPosted(sbn: StatusBarNotification?) { + sbn?.notification?.extras?.let { bundle -> + bundle.getParcelable(Notification.EXTRA_MEDIA_SESSION)?.let { + MediaPlayerHelper.updatePlayingMediaInfo(this) + } + } + super.onNotificationPosted(sbn) + } + + override fun onNotificationRemoved(sbn: StatusBarNotification?) { + MediaPlayerHelper.updatePlayingMediaInfo(this) + super.onNotificationRemoved(sbn) + } +} \ No newline at end of file diff --git a/app/src/main/java/com/tommasoberlose/anotherwidget/ui/adapters/ViewPagerAdapter.kt b/app/src/main/java/com/tommasoberlose/anotherwidget/ui/adapters/ViewPagerAdapter.kt index c91c660..2d58cae 100644 --- a/app/src/main/java/com/tommasoberlose/anotherwidget/ui/adapters/ViewPagerAdapter.kt +++ b/app/src/main/java/com/tommasoberlose/anotherwidget/ui/adapters/ViewPagerAdapter.kt @@ -8,13 +8,14 @@ import com.tommasoberlose.anotherwidget.ui.fragments.* class ViewPagerAdapter(fragmentActivity: FragmentActivity) : FragmentStateAdapter(fragmentActivity) { - override fun getItemCount(): Int = 4 + override fun getItemCount(): Int = 5 override fun createFragment(position: Int): Fragment { return when (position) { 1 -> CalendarTabFragment.newInstance() 2 -> WeatherTabFragment.newInstance() 3 -> ClockTabFragment.newInstance() + 4 -> MusicTabFragment.newInstance() else -> GeneralTabFragment.newInstance() } } diff --git a/app/src/main/java/com/tommasoberlose/anotherwidget/ui/fragments/MainFragment.kt b/app/src/main/java/com/tommasoberlose/anotherwidget/ui/fragments/MainFragment.kt index 4ca4aac..bf1daf9 100644 --- a/app/src/main/java/com/tommasoberlose/anotherwidget/ui/fragments/MainFragment.kt +++ b/app/src/main/java/com/tommasoberlose/anotherwidget/ui/fragments/MainFragment.kt @@ -15,6 +15,7 @@ import android.view.View import android.view.ViewGroup import android.widget.RelativeLayout import androidx.core.animation.addListener +import androidx.core.app.NotificationManagerCompat import androidx.core.content.ContextCompat import androidx.core.view.isVisible import androidx.fragment.app.Fragment @@ -84,6 +85,7 @@ class MainFragment : Fragment(), SharedPreferences.OnSharedPreferenceChangeList 1 -> getString(R.string.settings_calendar_title) 2 -> getString(R.string.settings_weather_title) 3 -> getString(R.string.settings_clock_title) + 4 -> getString(R.string.settings_music_title) else -> "" } }.attach() @@ -261,18 +263,7 @@ class MainFragment : Fragment(), SharedPreferences.OnSharedPreferenceChangeList }.start() } - - // Calendar error indicator - tabs?.getTabAt(1)?.orCreateBadge?.apply { - backgroundColor = ContextCompat.getColor(requireContext(), R.color.errorColorText) - badgeGravity = BadgeDrawable.TOP_END - }?.isVisible = Preferences.showEvents && activity?.checkGrantedPermission(Manifest.permission.READ_CALENDAR) != true - - // Weather error indicator - tabs?.getTabAt(2)?.orCreateBadge?.apply { - backgroundColor = ContextCompat.getColor(requireContext(), R.color.errorColorText) - badgeGravity = BadgeDrawable.TOP_END - }?.isVisible = Preferences.showWeather && (Preferences.weatherProviderApi == "" || (Preferences.customLocationAdd == "" && activity?.checkGrantedPermission(if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.Q) Manifest.permission.ACCESS_BACKGROUND_LOCATION else Manifest.permission.ACCESS_FINE_LOCATION) != true)) + showErrorBadge() } @@ -301,8 +292,25 @@ class MainFragment : Fragment(), SharedPreferences.OnSharedPreferenceChangeList } } - override fun onDestroy() { - super.onDestroy() + private fun showErrorBadge() { + // Calendar error indicator + tabs?.getTabAt(1)?.orCreateBadge?.apply { + backgroundColor = ContextCompat.getColor(requireContext(), R.color.errorColorText) + badgeGravity = BadgeDrawable.TOP_END + }?.isVisible = Preferences.showEvents && activity?.checkGrantedPermission(Manifest.permission.READ_CALENDAR) != true + + // Weather error indicator + tabs?.getTabAt(2)?.orCreateBadge?.apply { + backgroundColor = ContextCompat.getColor(requireContext(), R.color.errorColorText) + badgeGravity = BadgeDrawable.TOP_END + }?.isVisible = Preferences.showWeather && (Preferences.weatherProviderApi == "" || (Preferences.customLocationAdd == "" && activity?.checkGrantedPermission(if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.Q) Manifest.permission.ACCESS_BACKGROUND_LOCATION else Manifest.permission.ACCESS_FINE_LOCATION) != true)) + + + // Music error indicator + tabs?.getTabAt(4)?.orCreateBadge?.apply { + backgroundColor = ContextCompat.getColor(requireContext(), R.color.errorColorText) + badgeGravity = BadgeDrawable.TOP_END + }?.isVisible = Preferences.showMusic && !NotificationManagerCompat.getEnabledListenerPackages(requireContext()).contains(requireContext().packageName) } override fun onSharedPreferenceChanged(preferences: SharedPreferences, p1: String) { @@ -314,6 +322,7 @@ class MainFragment : Fragment(), SharedPreferences.OnSharedPreferenceChangeList super.onResume() Preferences.preferences.registerOnSharedPreferenceChangeListener(this) EventBus.getDefault().register(this) + showErrorBadge() } override fun onPause() { diff --git a/app/src/main/java/com/tommasoberlose/anotherwidget/ui/fragments/MusicTabFragment.kt b/app/src/main/java/com/tommasoberlose/anotherwidget/ui/fragments/MusicTabFragment.kt new file mode 100644 index 0000000..ec92480 --- /dev/null +++ b/app/src/main/java/com/tommasoberlose/anotherwidget/ui/fragments/MusicTabFragment.kt @@ -0,0 +1,144 @@ +package com.tommasoberlose.anotherwidget.ui.fragments + +import android.Manifest +import android.app.Activity +import android.content.Intent +import android.os.Build +import android.os.Bundle +import android.view.LayoutInflater +import android.view.View +import android.view.ViewGroup +import androidx.core.app.NotificationManagerCompat +import androidx.core.content.ContextCompat +import androidx.core.view.isVisible +import androidx.databinding.DataBindingUtil +import androidx.fragment.app.Fragment +import androidx.lifecycle.Observer +import androidx.lifecycle.ViewModelProvider +import androidx.lifecycle.lifecycleScope +import com.chibatching.kotpref.bulk +import com.karumi.dexter.Dexter +import com.karumi.dexter.MultiplePermissionsReport +import com.karumi.dexter.PermissionToken +import com.karumi.dexter.listener.PermissionRequest +import com.karumi.dexter.listener.multi.MultiplePermissionsListener +import com.tommasoberlose.anotherwidget.R +import com.tommasoberlose.anotherwidget.components.BottomSheetMenu +import com.tommasoberlose.anotherwidget.databinding.FragmentMusicSettingsBinding +import com.tommasoberlose.anotherwidget.databinding.FragmentWeatherSettingsBinding +import com.tommasoberlose.anotherwidget.global.Constants +import com.tommasoberlose.anotherwidget.global.Preferences +import com.tommasoberlose.anotherwidget.global.RequestCode +import com.tommasoberlose.anotherwidget.helpers.MediaPlayerHelper +import com.tommasoberlose.anotherwidget.helpers.SettingsStringHelper +import com.tommasoberlose.anotherwidget.receivers.WeatherReceiver +import com.tommasoberlose.anotherwidget.ui.activities.ChooseApplicationActivity +import com.tommasoberlose.anotherwidget.ui.activities.CustomLocationActivity +import com.tommasoberlose.anotherwidget.ui.activities.MainActivity +import com.tommasoberlose.anotherwidget.ui.activities.WeatherProviderActivity +import com.tommasoberlose.anotherwidget.ui.viewmodels.MainViewModel +import com.tommasoberlose.anotherwidget.ui.widgets.MainWidget +import com.tommasoberlose.anotherwidget.utils.checkGrantedPermission +import kotlinx.android.synthetic.main.fragment_music_settings.* +import kotlinx.coroutines.delay +import kotlinx.coroutines.launch + +class MusicTabFragment : Fragment() { + + companion object { + fun newInstance() = MusicTabFragment() + } + + private lateinit var viewModel: MainViewModel + + override fun onCreate(savedInstanceState: Bundle?) { + super.onCreate(savedInstanceState) + } + + override fun onCreateView( + inflater: LayoutInflater, container: ViewGroup?, + savedInstanceState: Bundle? + ): View { + + viewModel = ViewModelProvider(activity as MainActivity).get(MainViewModel::class.java) + val binding = DataBindingUtil.inflate(inflater, R.layout.fragment_music_settings, container, false) + + subscribeUi(binding, viewModel) + + binding.lifecycleOwner = this + binding.viewModel = viewModel + + return binding.root + } + + override fun onActivityCreated(savedInstanceState: Bundle?) { + super.onActivityCreated(savedInstanceState) + + setupListener() + } + + private fun subscribeUi( + binding: FragmentMusicSettingsBinding, + viewModel: MainViewModel + ) { + + viewModel.showMusic.observe(viewLifecycleOwner, Observer { + binding.isMusicVisible = Preferences.showMusic + checkNotificationPermission() + }) + + viewModel.mediaInfoFormat.observe(viewLifecycleOwner, Observer { + maintainScrollPosition { + label_music_info_format?.text = + if (it != "") it else getString(R.string.default_weather_app) + } + }) + } + + private fun setupListener() { + action_show_music.setOnClickListener { + Preferences.showMusic = !Preferences.showMusic + } + + action_music_info_format.setOnClickListener { + if (Preferences.showMusic) { +// startActivityForResult( +// Intent(requireContext(), WeatherProviderActivity::class.java), +// RequestCode.WEATHER_PROVIDER_REQUEST_CODE.code +// ) + } + } + + } + + private fun checkNotificationPermission() { + if (NotificationManagerCompat.getEnabledListenerPackages(requireContext()).contains(requireContext().packageName)) { + notification_permission_alert?.isVisible = false + MediaPlayerHelper.updatePlayingMediaInfo(requireContext()) + show_music_label?.text = if (Preferences.showMusic) getString(R.string.settings_show_music_enabled_subtitle) else getString(R.string.settings_show_music_disabled_subtitle) + } else if (Preferences.showMusic) { + notification_permission_alert?.isVisible = true + show_music_label?.text = getString(R.string.settings_request_notification_access) + notification_permission_alert?.setOnClickListener { + activity?.startActivity(Intent("android.settings.ACTION_NOTIFICATION_LISTENER_SETTINGS")) + } + } else { + show_music_label?.text = getString(R.string.settings_show_music_disabled_subtitle) + notification_permission_alert?.isVisible = false + } + } + + private fun maintainScrollPosition(callback: () -> Unit) { + val scrollPosition = scrollView.scrollY + callback.invoke() + lifecycleScope.launch { + delay(200) + scrollView.smoothScrollTo(0, scrollPosition) + } + } + + override fun onResume() { + super.onResume() + checkNotificationPermission() + } +} diff --git a/app/src/main/java/com/tommasoberlose/anotherwidget/ui/fragments/SettingsFragment.kt b/app/src/main/java/com/tommasoberlose/anotherwidget/ui/fragments/SettingsFragment.kt index 3909452..2123691 100644 --- a/app/src/main/java/com/tommasoberlose/anotherwidget/ui/fragments/SettingsFragment.kt +++ b/app/src/main/java/com/tommasoberlose/anotherwidget/ui/fragments/SettingsFragment.kt @@ -30,6 +30,7 @@ import com.tommasoberlose.anotherwidget.ui.activities.MainActivity import com.tommasoberlose.anotherwidget.ui.activities.SupportDevActivity import com.tommasoberlose.anotherwidget.ui.viewmodels.MainViewModel import com.tommasoberlose.anotherwidget.helpers.CalendarHelper +import com.tommasoberlose.anotherwidget.helpers.MediaPlayerHelper import com.tommasoberlose.anotherwidget.helpers.WeatherHelper import com.tommasoberlose.anotherwidget.utils.checkGrantedPermission import com.tommasoberlose.anotherwidget.utils.openURI @@ -195,6 +196,7 @@ class SettingsFragment : Fragment() { action_refresh_widget.setOnClickListener { WeatherHelper.updateWeather(requireContext()) CalendarHelper.updateEventList(requireContext()) + MediaPlayerHelper.updatePlayingMediaInfo(requireContext()) } } diff --git a/app/src/main/java/com/tommasoberlose/anotherwidget/ui/viewmodels/MainViewModel.kt b/app/src/main/java/com/tommasoberlose/anotherwidget/ui/viewmodels/MainViewModel.kt index 6a96136..8137797 100644 --- a/app/src/main/java/com/tommasoberlose/anotherwidget/ui/viewmodels/MainViewModel.kt +++ b/app/src/main/java/com/tommasoberlose/anotherwidget/ui/viewmodels/MainViewModel.kt @@ -52,6 +52,10 @@ class MainViewModel : ViewModel() { val showWeatherWarning = Preferences.asLiveData(Preferences::showWeatherWarning) + // Music + val showMusic = Preferences.asLiveData(Preferences::showMusic) + val mediaInfoFormat = Preferences.asLiveData(Preferences::mediaInfoFormat) + // Advanced Settings val darkThemePreference = Preferences.asLiveData(Preferences::darkThemePreference) val showWallpaper = Preferences.asLiveData(Preferences::showWallpaper) diff --git a/app/src/main/java/com/tommasoberlose/anotherwidget/ui/widgets/MainWidget.kt b/app/src/main/java/com/tommasoberlose/anotherwidget/ui/widgets/MainWidget.kt index eb27f53..8efb69e 100644 --- a/app/src/main/java/com/tommasoberlose/anotherwidget/ui/widgets/MainWidget.kt +++ b/app/src/main/java/com/tommasoberlose/anotherwidget/ui/widgets/MainWidget.kt @@ -12,6 +12,7 @@ import android.graphics.Color import android.graphics.Typeface import android.os.Bundle import android.text.format.DateUtils +import android.util.Log import android.util.TypedValue import android.view.View import android.widget.ImageView @@ -54,6 +55,7 @@ class MainWidget : AppWidgetProvider() { override fun onEnabled(context: Context) { CalendarHelper.updateEventList(context) WeatherReceiver.setUpdates(context) + MediaPlayerHelper.updatePlayingMediaInfo(context) if (Preferences.showEvents) { CalendarHelper.setEventUpdatesAndroidN(context) @@ -149,6 +151,7 @@ class MainWidget : AppWidgetProvider() { views.setViewVisibility(R.id.empty_layout_rect, View.VISIBLE) views.setViewVisibility(R.id.calendar_layout_rect, View.GONE) views.setViewVisibility(R.id.second_row_rect, View.GONE) + views.setViewVisibility(R.id.next_event_difference_time_rect, View.GONE) val calPIntent = PendingIntent.getActivity( context, @@ -280,6 +283,28 @@ class MainWidget : AppWidgetProvider() { ) views.setViewVisibility(R.id.second_row_rect, View.VISIBLE) + views.setViewVisibility(R.id.empty_layout_rect, View.GONE) + views.setViewVisibility(R.id.calendar_layout_rect, View.VISIBLE) + } else if (MediaPlayerHelper.isSomeonePlaying(context)) { + val musicIntent = PendingIntent.getActivity( + context, + widgetID, + IntentHelper.getMusicIntent(context), + 0 + ) + views.setOnClickPendingIntent(R.id.second_row_rect, musicIntent) + + views.setImageViewBitmap( + R.id.next_event_rect, + BitmapHelper.getBitmapFromView(v.next_event, draw = false) + ) + + views.setImageViewBitmap( + R.id.second_row_rect, + BitmapHelper.getBitmapFromView(v.second_row, draw = false) + ) + views.setViewVisibility(R.id.second_row_rect, View.VISIBLE) + views.setViewVisibility(R.id.empty_layout_rect, View.GONE) views.setViewVisibility(R.id.calendar_layout_rect, View.VISIBLE) } @@ -296,6 +321,7 @@ class MainWidget : AppWidgetProvider() { if (Preferences.showWeather && Preferences.weatherIcon != "") { views.setViewVisibility(R.id.weather_rect, View.VISIBLE) views.setViewVisibility(R.id.calendar_weather_rect, View.VISIBLE) + views.setViewVisibility(R.id.special_weather_rect, View.VISIBLE) val i = Intent(context, WidgetClickListenerReceiver::class.java) i.action = Actions.ACTION_OPEN_WEATHER_INTENT @@ -303,6 +329,7 @@ class MainWidget : AppWidgetProvider() { views.setOnClickPendingIntent(R.id.weather_rect, weatherPIntent) views.setOnClickPendingIntent(R.id.calendar_weather_rect, weatherPIntent) + views.setOnClickPendingIntent(R.id.special_weather_rect, weatherPIntent) views.setImageViewBitmap( R.id.weather_rect, @@ -313,9 +340,21 @@ class MainWidget : AppWidgetProvider() { R.id.calendar_weather_rect, BitmapHelper.getBitmapFromView(v.calendar_weather, draw = false) ) + + views.setImageViewBitmap( + R.id.special_weather_rect, + BitmapHelper.getBitmapFromView(v.calendar_weather, draw = false) + ) + + if (WidgetHelper.showSpecialWeather(context)) { + views.setViewVisibility(R.id.calendar_weather_rect, View.GONE) + } else { + views.setViewVisibility(R.id.special_weather_rect, View.GONE) + } } else { views.setViewVisibility(R.id.weather_rect, View.GONE) views.setViewVisibility(R.id.calendar_weather_rect, View.GONE) + views.setViewVisibility(R.id.special_weather_rect, View.GONE) } } catch (ex: Exception) { ex.printStackTrace() @@ -392,6 +431,7 @@ class MainWidget : AppWidgetProvider() { v.empty_layout.visibility = View.VISIBLE v.calendar_layout.visibility = View.GONE + v.next_event_difference_time.visibility = View.GONE v.action_next.isVisible = false v.action_previous.isVisible = false @@ -470,11 +510,22 @@ class MainWidget : AppWidgetProvider() { v.next_event_date.text = AlarmHelper.getNextAlarm(context) v.empty_layout.visibility = View.GONE v.calendar_layout.visibility = View.VISIBLE + } else if (MediaPlayerHelper.isSomeonePlaying(context)) { + v.second_row_icon.setImageDrawable( + ContextCompat.getDrawable( + context, + R.drawable.round_music_note + ) + ) + v.next_event.text = DateHelper.getDateText(context, now) + v.next_event_date.text = MediaPlayerHelper.getMediaInfo() + v.empty_layout.visibility = View.GONE + v.calendar_layout.visibility = View.VISIBLE } // Color - listOf(v.empty_date, v.divider1, v.temp, v.next_event, v.next_event_difference_time, v.next_event_date, v.divider2, v.calendar_temp).forEach { + listOf(v.empty_date, v.divider1, v.temp, v.next_event, v.next_event_difference_time, v.next_event_date, v.divider2, v.calendar_temp, v.divider3, v.special_temp).forEach { it.setTextColor(ColorHelper.getFontColor()) } @@ -485,13 +536,15 @@ class MainWidget : AppWidgetProvider() { // Text Size listOf>( v.empty_date to Preferences.textMainSize, - v.divider1 to Preferences.textMainSize, + v.divider1 to (Preferences.textMainSize - 2), v.temp to Preferences.textMainSize, v.next_event to Preferences.textMainSize, v.next_event_difference_time to Preferences.textMainSize, v.next_event_date to Preferences.textSecondSize, - v.divider2 to Preferences.textSecondSize, - v.calendar_temp to Preferences.textSecondSize + v.divider2 to (Preferences.textSecondSize - 2), + v.calendar_temp to Preferences.textSecondSize, + v.divider3 to (Preferences.textMainSize - 2), + v.special_temp to Preferences.textMainSize ).forEach { it.first.setTextSize(TypedValue.COMPLEX_UNIT_SP, it.second) } @@ -512,6 +565,9 @@ class MainWidget : AppWidgetProvider() { v.action_previous.scaleX = Preferences.textMainSize / 28f v.action_previous.scaleY = Preferences.textMainSize / 28f + v.special_weather_icon.scaleX = Preferences.textMainSize / 20f + v.special_weather_icon.scaleY = Preferences.textMainSize / 20f + // Shadows val shadowRadius = when (Preferences.textShadow) { @@ -533,14 +589,14 @@ class MainWidget : AppWidgetProvider() { else -> 0f } - listOf(v.empty_date, v.divider1, v.temp, v.next_event, v.next_event_difference_time, v.next_event_date, v.divider2, v.calendar_temp).forEach { + listOf(v.empty_date, v.divider1, v.temp, v.next_event, v.next_event_difference_time, v.next_event_date, v.divider2, v.calendar_temp, v.divider3, v.special_temp).forEach { it.setShadowLayer(shadowRadius, 0f, shadowDy, shadowColor) } // Custom Font if (Preferences.customFont == Constants.CUSTOM_FONT_PRODUCT_SANS) { val productSans: Typeface = Typeface.createFromAsset(context.assets, "fonts/product_sans_regular.ttf") - listOf(v.empty_date, v.divider1, v.temp, v.next_event, v.next_event_difference_time, v.next_event_date, v.divider2, v.calendar_temp).forEach { + listOf(v.empty_date, v.divider1, v.temp, v.next_event, v.next_event_difference_time, v.next_event_date, v.divider2, v.calendar_temp, v.divider3, v.special_temp).forEach { it.typeface = productSans } } @@ -549,24 +605,36 @@ class MainWidget : AppWidgetProvider() { if (Preferences.showWeather && Preferences.weatherIcon != "") { v.weather.visibility = View.VISIBLE v.calendar_weather.visibility = View.VISIBLE + v.special_weather.visibility = View.VISIBLE val currentTemp = String.format(Locale.getDefault(), "%.0f °%s", Preferences.weatherTemp, Preferences.weatherRealTempUnit) val icon: String = Preferences.weatherIcon if (icon == "") { v.weather_icon.visibility = View.GONE v.empty_weather_icon.visibility = View.GONE + v.special_weather_icon.visibility = View.GONE } else { v.weather_icon.setImageResource(WeatherHelper.getWeatherIconResource(icon)) v.empty_weather_icon.setImageResource(WeatherHelper.getWeatherIconResource(icon)) + v.special_weather_icon.setImageResource(WeatherHelper.getWeatherIconResource(icon)) v.weather_icon.visibility = View.VISIBLE v.empty_weather_icon.visibility = View.VISIBLE + v.special_weather_icon.visibility = View.VISIBLE } v.temp.text = currentTemp v.calendar_temp.text = currentTemp + v.special_temp.text = currentTemp + + if (WidgetHelper.showSpecialWeather(context)) { + v.calendar_weather.visibility = View.GONE + } else { + v.special_weather.visibility = View.GONE + } } else { v.weather.visibility = View.GONE v.calendar_weather.visibility = View.GONE + v.special_weather.visibility = View.GONE } return v diff --git a/app/src/main/res/drawable-hdpi/round_music_note.png b/app/src/main/res/drawable-hdpi/round_music_note.png new file mode 100644 index 0000000000000000000000000000000000000000..1d614c976d97ae4ad9ea286f5a8240cd0b9f9fe3 GIT binary patch literal 405 zcmeAS@N?(olHy`uVBq!ia0vp^9w5xY1|&n@Zgyv2V2tr}aSW+oe0z)0#W_%-?V*4k zQ;TAYB1;29Lt;ZBhqHtN3&&vr1qUGEByq?9NE;krZF!g^(Y9Z_ans>zmOK9cjFV&d zvEzSZ^^z$;UYbio?pht=U8a#}edc42*rt_@{x{~iSv3Am+rYf{aB1xg`_c#7GFuwe z3Zg|57YOBT=9ng>k+Y`p&@QPL3z*k7KFi2huwQJ4GvldZg{6%q6WA^}NO>@4D)25r zh#Hwxe2lD48&I6|qv>e=C2D{9ZWwEyB} zjrqdX{YEZt*AX_clR~U9SDRfo92JfECXhIXFXp=ShvMjktvb8zJTAyLJSMs6HIuVX m;NPl4=@JV%s~`b!#azUj)gvgRU=c9589ZJ6T-G@yGywocYM*!j literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-hdpi/round_music_note_black_18.png b/app/src/main/res/drawable-hdpi/round_music_note_black_18.png new file mode 100644 index 0000000000000000000000000000000000000000..9fde6c76779040b53d4f79b26cf24788f430817a GIT binary patch literal 218 zcmV<0044v4P)7+7=*$6@(Y7t76$o+K@f(+oPr>~aDF+3VKA7}VDR>bkGl7oe9tD|bNAyv zK9jVum*b3ku)|ap>R>-AMeGD~bjT5PCCu>#)5KbQf(mP8>|k1|%Oc%$NbB_ItWGhEy=VJtr@4C_$p(qXGwe zqCm?*1&-a^hYuR;Pw+eJc+OFR&652mYodV!%fSb48xQ7PU#tJ)-+|wE{{E3iX!%s`W wHcO=-s*UT?$0Jg4T@#e@mq<8XZhFDYT(W<26Z7PkK(8=(y85}Sb4q9e07V^Sa{vGU literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-hdpi/round_music_note_black_36.png b/app/src/main/res/drawable-hdpi/round_music_note_black_36.png new file mode 100644 index 0000000000000000000000000000000000000000..6f1dffb72d22edc9863cdcb589355f16e03292b5 GIT binary patch literal 338 zcmeAS@N?(olHy`uVBq!ia0vp^W+2SL1|)l2v+go5FiLv5IEGX(zP-Wd?i?s_>|=o- zUz@-o1C|{P0&X16K(dX2k?qEDj>HDVJNyD|i46>lZ3Ye;hmYQtKd>XGeDQbNdG_`) z2M%+en>l$(ke8^2;hl@lC)Ncdb7y~S6+BeZ$eZKe&vB8btYN;!@}Ioc7i90G%i27( zT63oG2A6Bz;cF5Nk9eb#H!eQL!YNXGLuBD)172jb`P2+`hwF5q*c3Nr}Dr{fo7XNqNUBu`(vx9j|1h zZwT5w*u?pU<9k8mA@w!Q1Y=i9;502o*RjCQhs&WFmTBLax?|Er1 c{kPNpSkopk=h){vfMLbp>FVdQ&MBb@05DmI7XSbN literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-hdpi/round_queue_music.png b/app/src/main/res/drawable-hdpi/round_queue_music.png new file mode 100644 index 0000000000000000000000000000000000000000..15b261536d4bdb20ec033479e24a57bd83d9c185 GIT binary patch literal 360 zcmV-u0hj)XP)8%fI|oXAq*kF0Aqk51PEa`0KgE25Dp;#1b{Gv5Dp;#zyJprh7bmL`(xm9 zKKJ70`_A*{2Y`oj?{`K@DW#NBN~xe3)&r?fB36MLEU^yUqJX+9pA75Gdvtk@twqhb{yYu&7VGhY0=-BbShPj7jP(9XRpJN@?z?|NZd>fe43zF|1<}^q0mDo8( zZBZbL=8o6P6j^nL-^i#v7Ra(oJfRIfy=PotEGeawQtBT-2``76%=F6u0000;3AQGG4FvA2YuY=Db8zBA+#Q#aa`DpsDBgy>+;$U2sX#nwaLKfgLY%`kt zXRrfk1nxsEiANJ3c*|ITcsda8Ck8``V>Kuo7tb@-(U%Ov}j4)Q6Gchy#dkqpP7+oCSjnrk7>Wcr0_Ewq*i9 z{2q%%pTR*)Re;Eo-(eO(+5R-kSkTm24#f%#!wQT70C3ueR5K%*5dZ)H07*qoM6N<$ Ef}*}-S^xk5 literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-hdpi/round_queue_music_black_24.png b/app/src/main/res/drawable-hdpi/round_queue_music_black_24.png new file mode 100644 index 0000000000000000000000000000000000000000..50d882d9be298a202635133137675b2caf57cf64 GIT binary patch literal 257 zcmeAS@N?(olHy`uVBq!ia0vp^Dj>|k1|%Oc%$NbBPI$UFhEy=Vz1+xlC_tqBqd*%2 z<2MFH9svaf7LMu$Ad9hTi6RS!?ID3f4B`TZ1pMT?c5Z1d6gzjkpV4~9|B1_=SI(RM zi0S3S7S3C#7LOT!a-6sr$@o(H*F_1&rW?F-&jvVGtuQ#cotI@JTlI|c7KWPDKOGOR z_pv`wmU_zZoAzh-x7wGli;B0v@#&WP z`KHx$AD%BO5B(~VSP_;um5+ICNQ8HLW07dsGP{3<=iFM&gYU2MUK1*8%2nQ}yj3fF zv61!1`)k93O}%DDt@?C6yrDU2_0C-dpwMWLf3WGI)fDl3mJwkxcTZJAVgs=w~!T`e_AnXx_A%r0W7+?se4}p6vE#M$n!jJg%mZUr$T}`RJKM78PI4QQ9wpYpssepfC}o832xR0q?QM?SXmsi_@%07*qoM6N<$f@qU&EC2ui literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-mdpi/round_music_note_black_18.png b/app/src/main/res/drawable-mdpi/round_music_note_black_18.png new file mode 100644 index 0000000000000000000000000000000000000000..b1f65f075829f1a44aac6d3b23d81e828109d23a GIT binary patch literal 175 zcmeAS@N?(olHy`uVBq!ia0vp^LLkh+1|-AI^@RheGEW!BkP60RiA@I>JHnYi)+y+* zC5aXBR`DJAKXHS3LH@MXiiM?s)JI7g_bMXmOeJ{Xbov*Y4~9{OY!*0UPDQRc|2#A{7pFAF2lg^ YXsJF|gmm8(pbHp0UHx3vIVCg!0J`ovkN^Mx literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-mdpi/round_music_note_black_24.png b/app/src/main/res/drawable-mdpi/round_music_note_black_24.png new file mode 100644 index 0000000000000000000000000000000000000000..890661da819f63ef039b47a907b7721bd4bb0b8b GIT binary patch literal 181 zcmeAS@N?(olHy`uVBq!ia0vp^5+KaM1|%Pp+x`GjHJ&bxAr*{oFEp|?1c|k1|%Oc%$NbB_ItWGhEy=VJtr@4C_$p(qXGwe zqCm?*1&-a^hYuR;Pw+eJc+OFR&652mYodV!%fSb48xQ7PU#tJ)-+|wE{{E3iX!%s`W wHcO=-s*UT?$0Jg4T@#e@mq<8XZhFDYT(W<26Z7PkK(8=(y85}Sb4q9e07V^Sa{vGU literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-mdpi/round_queue_music.png b/app/src/main/res/drawable-mdpi/round_queue_music.png new file mode 100644 index 0000000000000000000000000000000000000000..50d882d9be298a202635133137675b2caf57cf64 GIT binary patch literal 257 zcmeAS@N?(olHy`uVBq!ia0vp^Dj>|k1|%Oc%$NbBPI$UFhEy=Vz1+xlC_tqBqd*%2 z<2MFH9svaf7LMu$Ad9hTi6RS!?ID3f4B`TZ1pMT?c5Z1d6gzjkpV4~9|B1_=SI(RM zi0S3S7S3C#7LOT!a-6sr$@o(H*F_1&rW?F-&jvVGtuQ#cotI@JTlI|c7KWPDKOGOR z_pv`wmU_zZoAzh-x7wGlik=7w~RI7R^y}F4_Z9bPOv}v9`MG#smO-mYk>7kAwQOS Ppw$eXu6{1-oD!MtwmcJ2v+}3s@F2Ftlc5{g-IwWCYsF N;OXk;vd$@?2>`TqIN$&P literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-mdpi/round_queue_music_black_48.png b/app/src/main/res/drawable-mdpi/round_queue_music_black_48.png new file mode 100644 index 0000000000000000000000000000000000000000..2747e2e582b38f272e74f9e8acc02c3f1b2f45ac GIT binary patch literal 283 zcmV+$0p$LPP)Dr(Aq)XR2oO5L?$7~3#~5~$9U%-mK-dAohY)sz9brM>+xU9v<4yk`0p3r~ zW_!mX5fKp)DS;a>efie`N0#k?1_i~&7!t!*ytlqn(rC3B-; z&Y}1ZXP^KD_}c^a0MC2C9^h&Z*aIBw0X@VHC_sC_{@uO;F7LAkAOKfyd!S?47Pu$p z9qfUgxwY}4WZnbz_k3kM$DQ!&0nH3lLgA}{_Sxwv7)sE_~v002ovPDHLkV1n;0ZRr32 literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-xhdpi/round_music_note.png b/app/src/main/res/drawable-xhdpi/round_music_note.png new file mode 100644 index 0000000000000000000000000000000000000000..42c93baa22f6c6b266ecae148cfee5df811054c8 GIT binary patch literal 525 zcmeAS@N?(olHy`uVBq!ia0vp^2_VeD1|%QND7Ro>V7%h#;uuoF`1S^4igcpPv4`xA zfjoy9yACt3@-VYWFtjB#FfP#OTBy;bB+;};BB3FXqivB!*CGp^g90LsA9!a3MPG_u zH~*8}9)=J958hRux3L2XG74L`OEk2vC3ZQREZQ#Ux54G*PS$T?(~F3rhj0$K^E~dI~xxF_g+I4v|=N)QItw zrTfaw6^*V;S3WZ?z4u6m@zpNRhF!Z@R%C~L{879pIznq>Fj$GOR$=Eu8x%Ot5(WgAvLIe&|3dB)LWCN~aCO#j|==Hf%P i^osuJN-!{Q=KY&;3F%jv_i6#7nZeW5&t;ucLK6VMmD9uk literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-xhdpi/round_music_note_black_18.png b/app/src/main/res/drawable-xhdpi/round_music_note_black_18.png new file mode 100644 index 0000000000000000000000000000000000000000..cd6bdd16d322f5f6108bd55b197b5f730d022ef4 GIT binary patch literal 248 zcmeAS@N?(olHy`uVBq!ia0vp^Dj>|k1|%Oc%$NbB_ItWGhEy=VJtr@4C_$p(qXGwe zqCm?*1&-a^hYuR;Pw+eJc+OFR&652mYodV!%fSb48xQ7PU#tJ)-+|wE{{E3iX!%s`W wHcO=-s*UT?$0Jg4T@#e@mq<8XZhFDYT(W<26Z7PkK(8=(y85}Sb4q9e07V^Sa{vGU literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-xhdpi/round_music_note_black_24.png b/app/src/main/res/drawable-xhdpi/round_music_note_black_24.png new file mode 100644 index 0000000000000000000000000000000000000000..f58eb504d6cdf8d384aef79f4573059acded8b22 GIT binary patch literal 286 zcmV+(0pb3MP)I)fDl3mJwkxcTZJAVgs=w~!T`e_AnXx_A%r0W7+?se4}p6vE#M$n!jJg%mZUr$T}`RJKM78PI4QQ9wpYpssepfC}o832xR0q?QM?SXmsi_@%07*qoM6N<$f@qU&EC2ui literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-xhdpi/round_music_note_black_36.png b/app/src/main/res/drawable-xhdpi/round_music_note_black_36.png new file mode 100644 index 0000000000000000000000000000000000000000..1d614c976d97ae4ad9ea286f5a8240cd0b9f9fe3 GIT binary patch literal 405 zcmeAS@N?(olHy`uVBq!ia0vp^9w5xY1|&n@Zgyv2V2tr}aSW+oe0z)0#W_%-?V*4k zQ;TAYB1;29Lt;ZBhqHtN3&&vr1qUGEByq?9NE;krZF!g^(Y9Z_ans>zmOK9cjFV&d zvEzSZ^^z$;UYbio?pht=U8a#}edc42*rt_@{x{~iSv3Am+rYf{aB1xg`_c#7GFuwe z3Zg|57YOBT=9ng>k+Y`p&@QPL3z*k7KFi2huwQJ4GvldZg{6%q6WA^}NO>@4D)25r zh#Hwxe2lD48&I6|qv>e=C2D{9ZWwEyB} zjrqdX{YEZt*AX_clR~U9SDRfo92JfECXhIXFXp=ShvMjktvb8zJTAyLJSMs6HIuVX m;NPl4=@JV%s~`b!#azUj)gvgRU=c9589ZJ6T-G@yGywocYM*!j literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-xhdpi/round_queue_music.png b/app/src/main/res/drawable-xhdpi/round_queue_music.png new file mode 100644 index 0000000000000000000000000000000000000000..09521a9086cb0ba0509f6775426941c5d104f612 GIT binary patch literal 412 zcmeAS@N?(olHy`uVBq!ia0vp^9w5xY1|&n@Zgyv2U`+OOaSW+oe0!78g*j2;*vEnf z1_6dPMus-#1P*~VMkfmf77oTkK!t1#hYeZ|EAlu?@F^ZBXehAdII{QK%hc`P|Jnaz zxc^C@`YqQxps^s3^2+mVX!$a)(%B!r-&?<LEMo(N)qOt()$wC~r5P{D$4+f?wo4 znR`Ch_%arFeXaaZX?*u}16$MzyXg7mmt$AEU!7ApV{ujB%vZ%F6~=nW9S@Tg*pfgf z&+va^)7_+h%&fbQ{$b}T>;B0v@#&WP z`KHx$AD%BO5B(~VSP_;um5+ICNQ8HLW07dsGP{3<=iFM&gYU2MUK1*8%2nQ}yj3fF zv61!1`)k93O}%DDt@?C6yrDU2_0C-dpwMWLf3WG|k1|%Oc%$NbBPI$UFhEy=Vz1+xlC_tqBqd*%2 z<2MFH9svaf7LMu$Ad9hTi6RS!?ID3f4B`TZ1pMT?c5Z1d6gzjkpV4~9|B1_=SI(RM zi0S3S7S3C#7LOT!a-6sr$@o(H*F_1&rW?F-&jvVGtuQ#cotI@JTlI|c7KWPDKOGOR z_pv`wmU_zZoAzh-x7wGliDr(Aq)XR2oO5L?$7~3#~5~$9U%-mK-dAohY)sz9brM>+xU9v<4yk`0p3r~ zW_!mX5fKp)DS;a>efie`N0#k?1_i~&7!t!*ytlqn(rC3B-; z&Y}1ZXP^KD_}c^a0MC2C9^h&Z*aIBw0X@VHC_sC_{@uO;F7LAkAOKfyd!S?47Pu$p z9qfUgxwY}4WZnbz_k3kM$DQ!&0nH3lLgA}{_Sxwv7)sE_~v002ovPDHLkV1n;0ZRr32 literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-xhdpi/round_queue_music_black_48.png b/app/src/main/res/drawable-xhdpi/round_queue_music_black_48.png new file mode 100644 index 0000000000000000000000000000000000000000..90da09df4030a1631e449bc28bdddd00ead8ed1d GIT binary patch literal 507 zcmeAS@N?(olHy`uVBq!ia0vp^2_VeD1|%QND7Ro>U_9jM;uuoF`1TH?JBy=4!$WaK zCyosqiU9o!xZuyB*y7yqm$RKgktN~)5X&gYI7Q?XG|agDR{HXj+6V^u&t7ND z`8+47AkeMM2C)j}WA^{nHmVjJu~~jV_5x$=zsgMY17Z@|zkhYM7ctl{IKSA#;C~?E z<@PxRKh_(5ew3@tw;|2Gzwq;;+Ax_1bGNv@*;An}%AVnwo&5Z0G=p<%`+iobOTT_p zRx0gbm_JqKk8lA~rsQ)?jRu~ChF_8nYz9CE!*|A~%scos+FVzj_$0CS6J8*`Vb4U6MIw;u60Q=x4*Wrw!NAj z_?{(^t;g_~L~@T{=*nxav#OQe$$1(Ad%1fp5lC8YW``yaK3XOy=wt? z;^Bsslgv_jXDGI;*m$1DQF@ZvnJZ08*o;jTH4~SysTj^)uB&lTEabXa$YrsRP_ZZB zQ&>wEXltx{!SzXb1=pwQ08tU11)3-1c^9f{WcnOyxUH~cqXPFP+-R2D z&wy<$t#=mY=sXijwcb2I@Kji`qU@C1gHCb*+uX$-z7O1H+r7g1W}VH#8rx^j`vdpA zoVe50+3Cccbqb05Q~jn-_;{#h+xiI`XBkgtUBc6UX5qf38Se9E_9b&frF`Gx6mmX& z)dQ|WW!HTk#yZ~lEB!y@_Tk2F-Us4Y-xs9FAN!-o_q||wZS^zp{O#2i+xq#=U;kqB j{_Uq_s*%ayI67lr#2mTltfgx^C^dV!`njxgN@xNAvN#PB literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-xxhdpi/round_music_note_black_18.png b/app/src/main/res/drawable-xxhdpi/round_music_note_black_18.png new file mode 100644 index 0000000000000000000000000000000000000000..6f1dffb72d22edc9863cdcb589355f16e03292b5 GIT binary patch literal 338 zcmeAS@N?(olHy`uVBq!ia0vp^W+2SL1|)l2v+go5FiLv5IEGX(zP-Wd?i?s_>|=o- zUz@-o1C|{P0&X16K(dX2k?qEDj>HDVJNyD|i46>lZ3Ye;hmYQtKd>XGeDQbNdG_`) z2M%+en>l$(ke8^2;hl@lC)Ncdb7y~S6+BeZ$eZKe&vB8btYN;!@}Ioc7i90G%i27( zT63oG2A6Bz;cF5Nk9eb#H!eQL!YNXGLuBD)172jb`P2+`hwF5q*c3Nr}Dr{fo7XNqNUBu`(vx9j|1h zZwT5w*u?pU<9k8mA@w!Q1Y=i9;502o*RjCQhs&WFmTBLax?|Er1 c{kPNpSkopk=h){vfMLbp>FVdQ&MBb@05DmI7XSbN literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-xxhdpi/round_music_note_black_24.png b/app/src/main/res/drawable-xxhdpi/round_music_note_black_24.png new file mode 100644 index 0000000000000000000000000000000000000000..1d614c976d97ae4ad9ea286f5a8240cd0b9f9fe3 GIT binary patch literal 405 zcmeAS@N?(olHy`uVBq!ia0vp^9w5xY1|&n@Zgyv2V2tr}aSW+oe0z)0#W_%-?V*4k zQ;TAYB1;29Lt;ZBhqHtN3&&vr1qUGEByq?9NE;krZF!g^(Y9Z_ans>zmOK9cjFV&d zvEzSZ^^z$;UYbio?pht=U8a#}edc42*rt_@{x{~iSv3Am+rYf{aB1xg`_c#7GFuwe z3Zg|57YOBT=9ng>k+Y`p&@QPL3z*k7KFi2huwQJ4GvldZg{6%q6WA^}NO>@4D)25r zh#Hwxe2lD48&I6|qv>e=C2D{9ZWwEyB} zjrqdX{YEZt*AX_clR~U9SDRfo92JfECXhIXFXp=ShvMjktvb8zJTAyLJSMs6HIuVX m;NPl4=@JV%s~`b!#azUj)gvgRU=c9589ZJ6T-G@yGywocYM*!j literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-xxhdpi/round_music_note_black_36.png b/app/src/main/res/drawable-xxhdpi/round_music_note_black_36.png new file mode 100644 index 0000000000000000000000000000000000000000..5f5b818c8b128587a1066a30f762291c883c9351 GIT binary patch literal 588 zcmeAS@N?(olHy`uVBq!ia0vp^IUvlz1|<8_!p|}=FbR9QIEGX(zP-Vi5*;Yv{!vk* zNr|Ivkw)7>jy53?R{;k>mctCJEC&rl4jLRV5OFjRVdilT5IHKq;u^@}{NZgv!iP)G z_fD_2wC7{^QC#~@+jEi%7){vAH}`VKGHa7Xc3VApUtQGA)%5z({;b5wG^l%>rdF1B zc!==bfGZc&SItMmmqa%+M$Cos}CJ4+4X#*$8M`7qONky znQjx0Cs-}ZwQGLK4dlLTF#E}~jIp)3GH1%_33bm*XN2*EO>53w*)UI2DAScygmdc> zrl??*OS+;Lnv^D{g*XUzxkv>t#;TMkZd=)Kt23s{-otv^?Oo}bpr>mM%vaFJ~~^~>R+gLIX<=mnGg8%rFeySl2E7_Vydd$I4)`MZ2q zJ#=?1vF@65_hQ494UD=k3Xd;;uQqq#msxBk3pIN)zpOW(q7RF>e@v2YXOE@L3p56% O5(ZCKKbLh*2~7Y!YW4R3 literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-xxhdpi/round_queue_music.png b/app/src/main/res/drawable-xxhdpi/round_queue_music.png new file mode 100644 index 0000000000000000000000000000000000000000..6de1e898c7be3e177f773eacfd320c85b2c6515f GIT binary patch literal 618 zcmeAS@N?(olHy`uVBq!ia0vp^IUvlz1|<8_!p|}=Fd2HfIEGX(zP-)p!kj2^?4x+Q zz##!P4rd?~bmCBKNd#gBW`_m?1|G!&0zeU-!wiQFS`G`ey*{Y4!2kZBggbMnGdxz=8V9LCmIMu1&om@us@xroCFVaMlW&2RC<0t?CPX;!?Y65!=&Mx%I_A zZ3A4Gi?0R9uUZi(yfyKmk*UVVpR&az%ethlZ7cY$YG0kvS7j=@COffDW}dCFySS1uE73RzP{nTSDSYQ)#{!5 zH~rCt@EliGKHxU+*L{-iJM>_CE^u6{1-oD!ME^ literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-xxhdpi/round_queue_music_black_18.png b/app/src/main/res/drawable-xxhdpi/round_queue_music_black_18.png new file mode 100644 index 0000000000000000000000000000000000000000..15b261536d4bdb20ec033479e24a57bd83d9c185 GIT binary patch literal 360 zcmV-u0hj)XP)8%fI|oXAq*kF0Aqk51PEa`0KgE25Dp;#1b{Gv5Dp;#zyJprh7bmL`(xm9 zKKJ70`_A*{2Y`oj?{`K@DW#NBN~xe3)&r?fB36MLEU^yUqJX+9pA75Gdvtk@twqhb{yYu&7VGhY0=-BbShPj7jP(9XRpJN@?z?|NZd>fe43zF|1<}^q0mDo8( zZBZbL=8o6P6j^nL-^i#v7Ra(oJfRIfy=PotEGeawQtBT-2``76%=F6u0000;B0v@#&WP z`KHx$AD%BO5B(~VSP_;um5+ICNQ8HLW07dsGP{3<=iFM&gYU2MUK1*8%2nQ}yj3fF zv61!1`)k93O}%DDt@?C6yrDU2_0C-dpwMWLf3WGIci-0yZ@ ze|}(naPa)9viiMDK%>z?#j>zV%S$FMd-<=`)bswOv?{IqOUFy*>0RFPVy^5bv%fR! zgO;zn|EZww@|w%`)_tqn8l%Kyz}{U&DT*BtVwcvk3#b4ude^2-vlvb4`? zRitk``hQQ>tXUP)-vK$=@3wAOedS0d>-(IuUk|mv)Umzx+hp~FxodxJ`jB|bv%fUr zpmp@uU035}ez8@>0NLLaeV_GTQrYY4d*{l>bKll3Ic%c$pL5Zzx@FB*yn9O?%oSZ& zth`rI|#`Z*S&6Y->xOQfSgKBx= zEU5{*H%wZ`v*L-KPdZyjk@zxM=Bz65WeepWcfUJyr&TfltocBLfdUT)GZXV65Tm0@ z5@dLy!@EPT_TSdJ;J^FjkB9ev{<>W%wRC-^_SZYDSL?T5o%Xim+X;WQJ3F~o|Ib@} zB}z(s&*|6*SKg?9L8T$T%JqP%u5LK`vFCQh@%4_I%cI@v!jp zl}9cL-Fu_A=H2eKJ9|y4cQO}=o9X;n`tmAV^dOk^4=6v8@#2-NUFHh2Zka21&5;mL zJ;vtJ8O^-tNbT}P4gYQSd4{CjTF4lyre*x{Lc=-Xsgh+G4#zuB$&_R`>|SZKraZ-_ zeC2$tBcX5Q+YYOqDqAJ8w`B8?k3GRpC3G@vHgB1haisr?duRHh|MT}Rl>2@1_0LG( z{XOkMtNs7zUp!JVZ~s5x8h;aS_m$Ht6xm)bTe|sm?-A}R-qpPO*YsXeSi6TS!k;~J shFa#Y2hN$>Gw1kSs*CbPNq84_*`IG+cX;RYwWc6(Pgg&ebxsLQ0EWbD^Z)<= literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-xxxhdpi/round_music_note.png b/app/src/main/res/drawable-xxxhdpi/round_music_note.png new file mode 100644 index 0000000000000000000000000000000000000000..527c2208779bbec58d92af1376171daa41855f32 GIT binary patch literal 943 zcmeAS@N?(olHy`uVBq!ia0vp^2SAvE8Azrw%`pX1TLOGST!HkE13}e++klR?DGBlm zX0T~rfBgRc!>j8J1p1$Iu#~?~7TLd?N8`N2#TLJ# zKTi+8tm7R#J6+~=!bjiP3=B+po-U3d6^w81xK4ZQAmDn@AVp%SiLvv-w@LT@@2gs) zC&VN2|H^*t6Y9rA7;bbx!HNK#sdN7w4_&o&7ej^#^WSN!Ta#wzZ~f}-=&tkn+n4aa zjWbM3qz-53xb><_oz75D``LBuiumMZQqk@_Qs+&!DTq`*o8{nphBJLugK)9fEDzZP zZl>F9(`I>uu9=ykB)ZXUa^VX`;V%tFRSulC3p(Ti82C9@Y!-0JUC3)--@;)oVgC~K3S>gZ#n?VC3ekMbL10P5s zPuT0TWiRg>2`xMOcjj>}i~TpwnJl_{zdVrX&!Xk=Grxv&F#h}Gwcj*qCjSn*7yVV+ zn0LARdg)lQa>-uU8Tg`M*|J8vx}y^I4i3H>nb+lSU_REE#GWH+{UB^3^C8X(km#=R z2aMueas>?h7Mc|YY^x41+9a%bz{vlCQTj`RWtD@x?Sk*ene$Zg`)74d-eY-oNsruy z$$Pe%PTu)s?V_0?ALpHLjeTG{vBS#q-aM0TYyF+O58H91-s#qN-SGXVddYyH3?%)s? bgn)+nj*#hZU61O_17$l;S3j3^P6zmOK9cjFV&d zvEzSZ^^z$;UYbio?pht=U8a#}edc42*rt_@{x{~iSv3Am+rYf{aB1xg`_c#7GFuwe z3Zg|57YOBT=9ng>k+Y`p&@QPL3z*k7KFi2huwQJ4GvldZg{6%q6WA^}NO>@4D)25r zh#Hwxe2lD48&I6|qv>e=C2D{9ZWwEyB} zjrqdX{YEZt*AX_clR~U9SDRfo92JfECXhIXFXp=ShvMjktvb8zJTAyLJSMs6HIuVX m;NPl4=@JV%s~`b!#azUj)gvgRU=c9589ZJ6T-G@yGywocYM*!j literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-xxxhdpi/round_music_note_black_24.png b/app/src/main/res/drawable-xxxhdpi/round_music_note_black_24.png new file mode 100644 index 0000000000000000000000000000000000000000..42c93baa22f6c6b266ecae148cfee5df811054c8 GIT binary patch literal 525 zcmeAS@N?(olHy`uVBq!ia0vp^2_VeD1|%QND7Ro>V7%h#;uuoF`1S^4igcpPv4`xA zfjoy9yACt3@-VYWFtjB#FfP#OTBy;bB+;};BB3FXqivB!*CGp^g90LsA9!a3MPG_u zH~*8}9)=J958hRux3L2XG74L`OEk2vC3ZQREZQ#Ux54G*PS$T?(~F3rhj0$K^E~dI~xxF_g+I4v|=N)QItw zrTfaw6^*V;S3WZ?z4u6m@zpNRhF!Z@R%C~L{879pIznq>Fj$GOR$=Eu8x%Ot5(WgAvLIe&|3dB)LWCN~aCO#j|==Hf%P i^osuJN-!{Q=KY&;3F%jv_i6#7nZeW5&t;ucLK6VMmD9uk literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-xxxhdpi/round_music_note_black_36.png b/app/src/main/res/drawable-xxxhdpi/round_music_note_black_36.png new file mode 100644 index 0000000000000000000000000000000000000000..d7b8d7d1a7aa74b8b3fff1c2ffcbd7bdca5e1fc4 GIT binary patch literal 774 zcmeAS@N?(olHy`uVBq!ia0vp^6F``Q8Ax83A=Cw=RtNZmxB}^+0!&P|xB%U1SrX(I z%pelK`uP3-hZl$Q^#A@`@BaR=Np`Te%zTw{j^(F|ZCIkWe|He5et!M7#D0s{)AKJY z_&YbR@76e0Q=x4*Wrw!NAj z_?{(^t;g_~L~@T{=*nxav#OQe$$1(Ad%1fp5lC8YW``yaK3XOy=wt? z;^Bsslgv_jXDGI;*m$1DQF@ZvnJZ08*o;jTH4~SysTj^)uB&lTEabXa$YrsRP_ZZB zQ&>wEXltx{!SzXb1=pwQ08tU11)3-1c^9f{WcnOyxUH~cqXPFP+-R2D z&wy<$t#=mY=sXijwcb2I@Kji`qU@C1gHCb*+uX$-z7O1H+r7g1W}VH#8rx^j`vdpA zoVe50+3Cccbqb05Q~jn-_;{#h+xiI`XBkgtUBc6UX5qf38Se9E_9b&frF`Gx6mmX& z)dQ|WW!HTk#yZ~lEB!y@_Tk2F-Us4Y-xs9FAN!-o_q||wZS^zp{O#2i+xq#=U;kqB j{_Uq_s*%ayI67lr#2mTltfgx^C^dV!`njxgN@xNAvN#PB literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-xxxhdpi/round_queue_music.png b/app/src/main/res/drawable-xxxhdpi/round_queue_music.png new file mode 100644 index 0000000000000000000000000000000000000000..8a1ad293d8158532fabb1ccf6e604777651771b8 GIT binary patch literal 789 zcmeAS@N?(olHy`uVBq!ia0vp^6F``Q4M;wBd$farf$5H?i(^OyIci-0yZ@ ze|}(naPa)9viiMDK%>z?#j>zV%S$FMd-<=`)bswOv?{IqOUFy*>0RFPVy^5bv%fR! zgO;zn|EZww@|w%`)_tqn8l%Kyz}{U&DT*BtVwcvk3#b4ude^2-vlvb4`? zRitk``hQQ>tXUP)-vK$=@3wAOedS0d>-(IuUk|mv)Umzx+hp~FxodxJ`jB|bv%fUr zpmp@uU035}ez8@>0NLLaeV_GTQrYY4d*{l>bKll3Ic%c$pL5Zzx@FB*yn9O?%oSZ& zth`rI|#`Z*S&6Y->xOQfSgKBx= zEU5{*H%wZ`v*L-KPdZyjk@zxM=Bz65WeepWcfUJyr&TfltocBLfdUT)GZXV65Tm0@ z5@dLy!@EPT_TSdJ;J^FjkB9ev{<>W%wRC-^_SZYDSL?T5o%Xim+X;WQJ3F~o|Ib@} zB}z(s&*|6*SKg?9L8T$T%JqP%u5LK`vFCQh@%4_I%cI@v!jp zl}9cL-Fu_A=H2eKJ9|y4cQO}=o9X;n`tmAV^dOk^4=6v8@#2-NUFHh2Zka21&5;mL zJ;vtJ8O^-tNbT}P4gYQSd4{CjTF4lyre*x{Lc=-Xsgh+G4#zuB$&_R`>|SZKraZ-_ zeC2$tBcX5Q+YYOqDqAJ8w`B8?k3GRpC3G@vHgB1haisr?duRHh|MT}Rl>2@1_0LG( z{XOkMtNs7zUp!JVZ~s5x8h;aS_m$Ht6xm)bTe|sm?-A}R-qpPO*YsXeSi6TS!k;~J shFa#Y2hN$>Gw1kSs*CbPNq84_*`IG+cX;RYwWc6(Pgg&ebxsLQ0EWbD^Z)<= literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable-xxxhdpi/round_queue_music_black_18.png b/app/src/main/res/drawable-xxxhdpi/round_queue_music_black_18.png new file mode 100644 index 0000000000000000000000000000000000000000..09521a9086cb0ba0509f6775426941c5d104f612 GIT binary patch literal 412 zcmeAS@N?(olHy`uVBq!ia0vp^9w5xY1|&n@Zgyv2U`+OOaSW+oe0!78g*j2;*vEnf z1_6dPMus-#1P*~VMkfmf77oTkK!t1#hYeZ|EAlu?@F^ZBXehAdII{QK%hc`P|Jnaz zxc^C@`YqQxps^s3^2+mVX!$a)(%B!r-&?<LEMo(N)qOt()$wC~r5P{D$4+f?wo4 znR`Ch_%arFeXaaZX?*u}16$MzyXg7mmt$AEU!7ApV{ujB%vZ%F6~=nW9S@Tg*pfgf z&+va^)7_+h%&fbQ{$b}T>;B0v@#&WP z`KHx$AD%BO5B(~VSP_;um5+ICNQ8HLW07dsGP{3<=iFM&gYU2MUK1*8%2nQ}yj3fF zv61!1`)k93O}%DDt@?C6yrDU2_0C-dpwMWLf3WGU_9jM;uuoF`1TH?JBy=4!$WaK zCyosqiU9o!xZuyB*y7yqm$RKgktN~)5X&gYI7Q?XG|agDR{HXj+6V^u&t7ND z`8+47AkeMM2C)j}WA^{nHmVjJu~~jV_5x$=zsgMY17Z@|zkhYM7ctl{IKSA#;C~?E z<@PxRKh_(5ew3@tw;|2Gzwq;;+Ax_1bGNv@*;An}%AVnwo&5Z0G=p<%`+iobOTT_p zRx0gbm_JqKk8lA~rsQ)?jRu~ChF_8nYz9CE!*|A~%scos+FVzj_$0CS6J8*`Vb4U6MIw;u69H9e*gdeY6+Y6^(@`LzZVPiKVMw_ezJ&x#_Y$3=W{stujaXa+B@IE`Sa`G?J}E_ z6~dQKkH1|ndiU>T1_q|3o-U3d6^w5VGBPqSurMh6*e_WZ0%StKhfP(P)4N$%nj{#S z7}c70Z_fMwU+MW*x1jGurxeef7dOh;8FgN!ey`c>xwCG_FS-A*gsuNZg=z6bx!JFI zZJw=b5|k_@(Z^)Wk$XE zseCRgOU>7?{)DTq?^4B^pWByYWtvZH>#^4ecaF~N`q|tSboNKDN$8(I*L801q%%2x zKE8B1Qt=$C|H}_=t2d_~cVS>+;9(YQs-LTo@JgUzeY1S^%W`ImCb)kX7))vt*pEQ* z6d?Tt%5DMDEVU2bHWY(}K*GrQ3YdRjA(BZMzYn;swN>yGVR2+Q+b?r_+uNQ0&zkLd zwc@4xnkw@Q<coXCn3>`$!zbF-fM)Ts1t_dAV%iTo!@|G9dZJYg=H`@h0}VpEO7y3hL! z1y@Wqy4RrHYo3s`m(lk%?~dsF1DC3p%dSZ~yyoqgdE!77v(jt!k7ufwvo1V4=%RJu z*-4kMWBSFr4X;!hHVS_6G;Y-Wa&pSc-1r73<*L(;i{m=yu@$fQvTQkXiIo0}ryOg| zQmbyT2E0CYzARGX+7tDqq6s@$moiV;JykQqci}y^8{OyBB@F7Ozu2<-K*zlmXX?Kl z)qZngN&FwxQt87pUVonGb=0u@baio6>-zQI9yowg---WQ1w%qXfH9zJNnl$wvmQv? M)78&qol`;+0Dhcg6951J literal 0 HcmV?d00001 diff --git a/app/src/main/res/drawable/round_music_note_24.xml b/app/src/main/res/drawable/round_music_note_24.xml new file mode 100644 index 0000000..20ed3cc --- /dev/null +++ b/app/src/main/res/drawable/round_music_note_24.xml @@ -0,0 +1,10 @@ + + + diff --git a/app/src/main/res/drawable/round_queue_music_24.xml b/app/src/main/res/drawable/round_queue_music_24.xml new file mode 100644 index 0000000..23dd5f2 --- /dev/null +++ b/app/src/main/res/drawable/round_queue_music_24.xml @@ -0,0 +1,10 @@ + + + diff --git a/app/src/main/res/layout/fragment_music_settings.xml b/app/src/main/res/layout/fragment_music_settings.xml new file mode 100644 index 0000000..7f04ce9 --- /dev/null +++ b/app/src/main/res/layout/fragment_music_settings.xml @@ -0,0 +1,125 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/app/src/main/res/layout/the_widget.xml b/app/src/main/res/layout/the_widget.xml index 3bfaa8d..4304d14 100644 --- a/app/src/main/res/layout/the_widget.xml +++ b/app/src/main/res/layout/the_widget.xml @@ -102,6 +102,36 @@ android:layout_gravity="center_vertical" android:id="@+id/action_next" android:src="@drawable/round_chevron_right" /> + + + + + + The next alarm clock seems to be wrong.\nIt has been set by %s. Settings Clock text color + Music + Show current playing song + Playing song info visible + Playing song info hidden + Song info format + We need the notification access permission to check the current playing song. \ No newline at end of file diff --git a/app/src/main/res/values-fr/strings.xml b/app/src/main/res/values-fr/strings.xml index a3d1c2d..f2fe738 100644 --- a/app/src/main/res/values-fr/strings.xml +++ b/app/src/main/res/values-fr/strings.xml @@ -188,4 +188,10 @@ The next alarm clock seems to be wrong.\nIt has been set by %s. Settings Clock text color + Music + Show current playing song + Playing song info visible + Playing song info hidden + Song info format + We need the notification access permission to check the current playing song. \ No newline at end of file diff --git a/app/src/main/res/values-it/strings.xml b/app/src/main/res/values-it/strings.xml index 64a4f7e..56a1e42 100644 --- a/app/src/main/res/values-it/strings.xml +++ b/app/src/main/res/values-it/strings.xml @@ -187,4 +187,10 @@ La sveglia sembra impostata male.\nÈ stata impostata dall\'app %s. Impostazioni Colore orologio + Musica + Mostra brano in riproduzione + Visibile + Non visibile + Formato informazioni brano + Concedi all\'app il permesso di monitorare le notifiche, è necessario per poter mostrare il brano in riproduzione. \ No newline at end of file diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index 95441e6..fbf8579 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -199,4 +199,10 @@ The next alarm clock seems to be wrong.\nIt has been set by %s. Settings Clock text color + Music + Show current playing song + Playing song info visible + Playing song info hidden + Song info format + We need the notification access permission to check the current playing song. diff --git a/tasksintegration/build/intermediates/incremental/packageDebug/tmp/debug/dex-renamer-state.txt b/tasksintegration/build/intermediates/incremental/packageDebug/tmp/debug/dex-renamer-state.txt index 77c641a..7d6a280 100644 --- a/tasksintegration/build/intermediates/incremental/packageDebug/tmp/debug/dex-renamer-state.txt +++ b/tasksintegration/build/intermediates/incremental/packageDebug/tmp/debug/dex-renamer-state.txt @@ -1,4 +1,4 @@ -#Fri May 08 11:53:34 CEST 2020 +#Fri May 08 15:03:49 CEST 2020 base.0=/Users/tommaso/Documents/MyCode/another-widget/tasksintegration/build/intermediates/dex/debug/mergeProjectDexDebug/out/classes.dex path.0=classes.dex renamed.0=classes.dex diff --git a/tasksintegration/build/intermediates/incremental/packageDebug/tmp/debug/zip-cache/androidResources b/tasksintegration/build/intermediates/incremental/packageDebug/tmp/debug/zip-cache/androidResources index a7ddbbeb2b7567c50f4c00b82fcbcdde1503158a..c1e60cb0c17b4bd70ac399c8728866306955bfe5 100644 GIT binary patch delta 34 mcmbQtIGIs2z?+eY0Sq`87&sIeer0k`nmti8jPcCG9CZL^oClQv delta 34 mcmbQtIGIs2z?+eY0Sq`87&sIe)(Sgx%$g_~#&~*SjyeEgfd?A^