diff --git a/app/src/main/java/de/danoeh/antennapod/activity/BugReportActivity.java b/app/src/main/java/de/danoeh/antennapod/activity/BugReportActivity.java index 8d07eb969..e379b5eb2 100644 --- a/app/src/main/java/de/danoeh/antennapod/activity/BugReportActivity.java +++ b/app/src/main/java/de/danoeh/antennapod/activity/BugReportActivity.java @@ -21,7 +21,7 @@ import android.view.MenuItem; import android.widget.TextView; -import de.danoeh.antennapod.core.preferences.ThemeSwitcher; +import de.danoeh.antennapod.ui.common.ThemeSwitcher; import de.danoeh.antennapod.error.CrashReportWriter; import de.danoeh.antennapod.R; import de.danoeh.antennapod.storage.preferences.UserPreferences; diff --git a/app/src/main/java/de/danoeh/antennapod/activity/MainActivity.java b/app/src/main/java/de/danoeh/antennapod/activity/MainActivity.java index b4d45b262..48131f8da 100644 --- a/app/src/main/java/de/danoeh/antennapod/activity/MainActivity.java +++ b/app/src/main/java/de/danoeh/antennapod/activity/MainActivity.java @@ -35,7 +35,7 @@ import com.google.android.material.appbar.MaterialToolbar; import com.google.android.material.bottomsheet.BottomSheetBehavior; import com.google.android.material.snackbar.Snackbar; import de.danoeh.antennapod.R; -import de.danoeh.antennapod.core.preferences.ThemeSwitcher; +import de.danoeh.antennapod.ui.common.ThemeSwitcher; import de.danoeh.antennapod.core.receiver.MediaButtonReceiver; import de.danoeh.antennapod.core.sync.queue.SynchronizationQueueSink; import de.danoeh.antennapod.core.util.download.FeedUpdateManager; diff --git a/app/src/main/java/de/danoeh/antennapod/activity/OnlineFeedViewActivity.java b/app/src/main/java/de/danoeh/antennapod/activity/OnlineFeedViewActivity.java index 031117170..66d9a4556 100644 --- a/app/src/main/java/de/danoeh/antennapod/activity/OnlineFeedViewActivity.java +++ b/app/src/main/java/de/danoeh/antennapod/activity/OnlineFeedViewActivity.java @@ -30,7 +30,7 @@ import com.google.android.material.snackbar.Snackbar; import de.danoeh.antennapod.R; import de.danoeh.antennapod.adapter.FeedItemlistDescriptionAdapter; -import de.danoeh.antennapod.core.preferences.ThemeSwitcher; +import de.danoeh.antennapod.ui.common.ThemeSwitcher; import de.danoeh.antennapod.core.service.download.DownloadRequestCreator; import de.danoeh.antennapod.core.feed.FeedUrlNotFoundException; import de.danoeh.antennapod.core.storage.DBTasks; diff --git a/app/src/main/java/de/danoeh/antennapod/activity/OpmlImportActivity.java b/app/src/main/java/de/danoeh/antennapod/activity/OpmlImportActivity.java index caafe989d..7bd057988 100644 --- a/app/src/main/java/de/danoeh/antennapod/activity/OpmlImportActivity.java +++ b/app/src/main/java/de/danoeh/antennapod/activity/OpmlImportActivity.java @@ -26,7 +26,7 @@ import com.google.android.material.dialog.MaterialAlertDialogBuilder; import androidx.appcompat.app.AppCompatActivity; import androidx.core.app.ActivityCompat; import de.danoeh.antennapod.R; -import de.danoeh.antennapod.core.preferences.ThemeSwitcher; +import de.danoeh.antennapod.ui.common.ThemeSwitcher; import de.danoeh.antennapod.core.storage.DBTasks; import de.danoeh.antennapod.core.util.download.FeedUpdateManager; diff --git a/app/src/main/java/de/danoeh/antennapod/activity/PlaybackSpeedDialogActivity.java b/app/src/main/java/de/danoeh/antennapod/activity/PlaybackSpeedDialogActivity.java index eeaaf0e30..37f13272a 100644 --- a/app/src/main/java/de/danoeh/antennapod/activity/PlaybackSpeedDialogActivity.java +++ b/app/src/main/java/de/danoeh/antennapod/activity/PlaybackSpeedDialogActivity.java @@ -6,7 +6,7 @@ import androidx.appcompat.app.AppCompatActivity; import android.content.DialogInterface; import android.os.Bundle; -import de.danoeh.antennapod.core.preferences.ThemeSwitcher; +import de.danoeh.antennapod.ui.common.ThemeSwitcher; import de.danoeh.antennapod.dialog.VariableSpeedDialog; public class PlaybackSpeedDialogActivity extends AppCompatActivity { diff --git a/app/src/main/java/de/danoeh/antennapod/activity/PreferenceActivity.java b/app/src/main/java/de/danoeh/antennapod/activity/PreferenceActivity.java index 6202f62da..67669af78 100644 --- a/app/src/main/java/de/danoeh/antennapod/activity/PreferenceActivity.java +++ b/app/src/main/java/de/danoeh/antennapod/activity/PreferenceActivity.java @@ -20,7 +20,7 @@ import com.bytehamster.lib.preferencesearch.SearchPreferenceResultListener; import com.google.android.material.snackbar.Snackbar; import de.danoeh.antennapod.R; -import de.danoeh.antennapod.core.preferences.ThemeSwitcher; +import de.danoeh.antennapod.ui.common.ThemeSwitcher; import de.danoeh.antennapod.databinding.SettingsActivityBinding; import de.danoeh.antennapod.event.MessageEvent; import de.danoeh.antennapod.fragment.preferences.AutoDownloadPreferencesFragment; diff --git a/app/src/main/java/de/danoeh/antennapod/activity/SelectSubscriptionActivity.java b/app/src/main/java/de/danoeh/antennapod/activity/SelectSubscriptionActivity.java index 34e93bf22..de163c854 100644 --- a/app/src/main/java/de/danoeh/antennapod/activity/SelectSubscriptionActivity.java +++ b/app/src/main/java/de/danoeh/antennapod/activity/SelectSubscriptionActivity.java @@ -26,7 +26,7 @@ import java.util.ArrayList; import java.util.List; import de.danoeh.antennapod.R; -import de.danoeh.antennapod.core.preferences.ThemeSwitcher; +import de.danoeh.antennapod.ui.common.ThemeSwitcher; import de.danoeh.antennapod.core.storage.DBReader; import de.danoeh.antennapod.core.storage.NavDrawerData; import de.danoeh.antennapod.databinding.SubscriptionSelectionActivityBinding; diff --git a/app/src/main/java/de/danoeh/antennapod/activity/VideoplayerActivity.java b/app/src/main/java/de/danoeh/antennapod/activity/VideoplayerActivity.java index fc371090e..3b08674af 100644 --- a/app/src/main/java/de/danoeh/antennapod/activity/VideoplayerActivity.java +++ b/app/src/main/java/de/danoeh/antennapod/activity/VideoplayerActivity.java @@ -47,7 +47,7 @@ import de.danoeh.antennapod.storage.preferences.UserPreferences; import de.danoeh.antennapod.core.service.playback.PlaybackService; import de.danoeh.antennapod.core.storage.DBReader; import de.danoeh.antennapod.core.storage.DBWriter; -import de.danoeh.antennapod.core.util.Converter; +import de.danoeh.antennapod.ui.common.Converter; import de.danoeh.antennapod.core.util.FeedItemUtil; import de.danoeh.antennapod.core.util.IntentUtils; import de.danoeh.antennapod.core.util.ShareUtils; diff --git a/app/src/main/java/de/danoeh/antennapod/activity/WidgetConfigActivity.java b/app/src/main/java/de/danoeh/antennapod/activity/WidgetConfigActivity.java index c868ae8df..bfdf6fb63 100644 --- a/app/src/main/java/de/danoeh/antennapod/activity/WidgetConfigActivity.java +++ b/app/src/main/java/de/danoeh/antennapod/activity/WidgetConfigActivity.java @@ -12,9 +12,9 @@ import android.widget.SeekBar; import android.widget.TextView; import androidx.appcompat.app.AppCompatActivity; import de.danoeh.antennapod.R; -import de.danoeh.antennapod.core.preferences.ThemeSwitcher; import de.danoeh.antennapod.core.receiver.PlayerWidget; import de.danoeh.antennapod.core.widget.WidgetUpdaterWorker; +import de.danoeh.antennapod.ui.common.ThemeSwitcher; public class WidgetConfigActivity extends AppCompatActivity { private int appWidgetId = AppWidgetManager.INVALID_APPWIDGET_ID; diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/ChaptersListAdapter.java b/app/src/main/java/de/danoeh/antennapod/adapter/ChaptersListAdapter.java index 1589f06cc..8f9a77f76 100644 --- a/app/src/main/java/de/danoeh/antennapod/adapter/ChaptersListAdapter.java +++ b/app/src/main/java/de/danoeh/antennapod/adapter/ChaptersListAdapter.java @@ -17,7 +17,7 @@ import com.bumptech.glide.request.RequestOptions; import com.google.android.material.elevation.SurfaceColors; import de.danoeh.antennapod.R; import de.danoeh.antennapod.model.feed.Chapter; -import de.danoeh.antennapod.core.util.Converter; +import de.danoeh.antennapod.ui.common.Converter; import de.danoeh.antennapod.model.feed.EmbeddedChapterImage; import de.danoeh.antennapod.core.util.IntentUtils; import de.danoeh.antennapod.model.playback.Playable; diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/FeedItemlistDescriptionAdapter.java b/app/src/main/java/de/danoeh/antennapod/adapter/FeedItemlistDescriptionAdapter.java index 2827c2590..a8c29d9ee 100644 --- a/app/src/main/java/de/danoeh/antennapod/adapter/FeedItemlistDescriptionAdapter.java +++ b/app/src/main/java/de/danoeh/antennapod/adapter/FeedItemlistDescriptionAdapter.java @@ -17,7 +17,7 @@ import de.danoeh.antennapod.core.util.NetworkUtils; import de.danoeh.antennapod.model.playback.RemoteMedia; import de.danoeh.antennapod.model.feed.FeedItem; import de.danoeh.antennapod.core.service.playback.PlaybackService; -import de.danoeh.antennapod.core.util.DateFormatter; +import de.danoeh.antennapod.ui.common.DateFormatter; import de.danoeh.antennapod.model.playback.Playable; import de.danoeh.antennapod.core.util.playback.PlaybackServiceStarter; import de.danoeh.antennapod.core.util.syndication.HtmlToPlainText; diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/SleepTimerDialog.java b/app/src/main/java/de/danoeh/antennapod/dialog/SleepTimerDialog.java index 67eb74fbc..d77d1ac58 100644 --- a/app/src/main/java/de/danoeh/antennapod/dialog/SleepTimerDialog.java +++ b/app/src/main/java/de/danoeh/antennapod/dialog/SleepTimerDialog.java @@ -29,7 +29,7 @@ import java.util.Locale; import de.danoeh.antennapod.R; import de.danoeh.antennapod.core.preferences.SleepTimerPreferences; import de.danoeh.antennapod.core.service.playback.PlaybackService; -import de.danoeh.antennapod.core.util.Converter; +import de.danoeh.antennapod.ui.common.Converter; import de.danoeh.antennapod.core.util.playback.PlaybackController; import de.danoeh.antennapod.event.playback.SleepTimerUpdatedEvent; diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/AudioPlayerFragment.java b/app/src/main/java/de/danoeh/antennapod/fragment/AudioPlayerFragment.java index bf101445a..082bded55 100644 --- a/app/src/main/java/de/danoeh/antennapod/fragment/AudioPlayerFragment.java +++ b/app/src/main/java/de/danoeh/antennapod/fragment/AudioPlayerFragment.java @@ -38,7 +38,7 @@ import de.danoeh.antennapod.activity.MainActivity; import de.danoeh.antennapod.core.feed.util.PlaybackSpeedUtils; import de.danoeh.antennapod.core.receiver.MediaButtonReceiver; import de.danoeh.antennapod.core.util.ChapterUtils; -import de.danoeh.antennapod.core.util.Converter; +import de.danoeh.antennapod.ui.common.Converter; import de.danoeh.antennapod.core.util.TimeSpeedConverter; import de.danoeh.antennapod.core.util.playback.PlaybackController; import de.danoeh.antennapod.dialog.MediaPlayerErrorDialog; diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/CoverFragment.java b/app/src/main/java/de/danoeh/antennapod/fragment/CoverFragment.java index dc074a1ea..4314cdd7b 100644 --- a/app/src/main/java/de/danoeh/antennapod/fragment/CoverFragment.java +++ b/app/src/main/java/de/danoeh/antennapod/fragment/CoverFragment.java @@ -34,7 +34,7 @@ import de.danoeh.antennapod.R; import de.danoeh.antennapod.activity.MainActivity; import de.danoeh.antennapod.core.feed.util.ImageResourceUtils; import de.danoeh.antennapod.core.util.ChapterUtils; -import de.danoeh.antennapod.core.util.DateFormatter; +import de.danoeh.antennapod.ui.common.DateFormatter; import de.danoeh.antennapod.core.util.playback.PlaybackController; import de.danoeh.antennapod.databinding.CoverFragmentBinding; import de.danoeh.antennapod.event.playback.PlaybackPositionEvent; diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/ItemFragment.java b/app/src/main/java/de/danoeh/antennapod/fragment/ItemFragment.java index 94877811e..fd8e75d68 100644 --- a/app/src/main/java/de/danoeh/antennapod/fragment/ItemFragment.java +++ b/app/src/main/java/de/danoeh/antennapod/fragment/ItemFragment.java @@ -49,8 +49,8 @@ import de.danoeh.antennapod.core.preferences.UsageStatistics; import de.danoeh.antennapod.net.download.serviceinterface.DownloadServiceInterface; import de.danoeh.antennapod.storage.preferences.UserPreferences; import de.danoeh.antennapod.core.storage.DBReader; -import de.danoeh.antennapod.core.util.Converter; -import de.danoeh.antennapod.core.util.DateFormatter; +import de.danoeh.antennapod.ui.common.Converter; +import de.danoeh.antennapod.ui.common.DateFormatter; import de.danoeh.antennapod.ui.common.CircularProgressBar; import de.danoeh.antennapod.ui.common.ThemeUtils; import de.danoeh.antennapod.core.util.playback.PlaybackController; diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/QueueFragment.java b/app/src/main/java/de/danoeh/antennapod/fragment/QueueFragment.java index 5e9146fe9..f268f8469 100644 --- a/app/src/main/java/de/danoeh/antennapod/fragment/QueueFragment.java +++ b/app/src/main/java/de/danoeh/antennapod/fragment/QueueFragment.java @@ -43,7 +43,7 @@ import de.danoeh.antennapod.core.feed.util.PlaybackSpeedUtils; import de.danoeh.antennapod.core.menuhandler.MenuItemUtils; import de.danoeh.antennapod.core.storage.DBReader; import de.danoeh.antennapod.core.storage.DBWriter; -import de.danoeh.antennapod.core.util.Converter; +import de.danoeh.antennapod.ui.common.Converter; import de.danoeh.antennapod.core.util.FeedItemUtil; import de.danoeh.antennapod.core.util.download.FeedUpdateManager; import de.danoeh.antennapod.dialog.ItemSortDialog; diff --git a/app/src/main/java/de/danoeh/antennapod/view/ShownotesWebView.java b/app/src/main/java/de/danoeh/antennapod/view/ShownotesWebView.java index f66b114b3..c880ab5a6 100644 --- a/app/src/main/java/de/danoeh/antennapod/view/ShownotesWebView.java +++ b/app/src/main/java/de/danoeh/antennapod/view/ShownotesWebView.java @@ -25,7 +25,7 @@ import com.google.android.material.snackbar.Snackbar; import de.danoeh.antennapod.R; import de.danoeh.antennapod.activity.MainActivity; import de.danoeh.antennapod.core.menuhandler.MenuItemUtils; -import de.danoeh.antennapod.core.util.Converter; +import de.danoeh.antennapod.ui.common.Converter; import de.danoeh.antennapod.core.util.IntentUtils; import de.danoeh.antennapod.core.util.NetworkUtils; import de.danoeh.antennapod.core.util.ShareUtils; diff --git a/app/src/main/java/de/danoeh/antennapod/view/viewholder/EpisodeItemViewHolder.java b/app/src/main/java/de/danoeh/antennapod/view/viewholder/EpisodeItemViewHolder.java index 9f0350b17..8344c51cb 100644 --- a/app/src/main/java/de/danoeh/antennapod/view/viewholder/EpisodeItemViewHolder.java +++ b/app/src/main/java/de/danoeh/antennapod/view/viewholder/EpisodeItemViewHolder.java @@ -23,14 +23,14 @@ import de.danoeh.antennapod.adapter.actionbutton.ItemActionButton; import de.danoeh.antennapod.core.util.PlaybackStatus; import de.danoeh.antennapod.core.util.download.MediaSizeLoader; import de.danoeh.antennapod.event.playback.PlaybackPositionEvent; -import de.danoeh.antennapod.core.util.DateFormatter; +import de.danoeh.antennapod.ui.common.DateFormatter; import de.danoeh.antennapod.model.feed.FeedItem; import de.danoeh.antennapod.model.feed.FeedMedia; import de.danoeh.antennapod.model.playback.MediaType; import de.danoeh.antennapod.core.feed.util.ImageResourceUtils; import de.danoeh.antennapod.net.download.serviceinterface.DownloadServiceInterface; import de.danoeh.antennapod.storage.preferences.UserPreferences; -import de.danoeh.antennapod.core.util.Converter; +import de.danoeh.antennapod.ui.common.Converter; import de.danoeh.antennapod.core.util.NetworkUtils; import de.danoeh.antennapod.model.playback.Playable; import de.danoeh.antennapod.ui.common.CircularProgressBar; diff --git a/app/src/main/java/de/danoeh/antennapod/view/viewholder/HorizontalItemViewHolder.java b/app/src/main/java/de/danoeh/antennapod/view/viewholder/HorizontalItemViewHolder.java index 8d44f419e..c1657b303 100644 --- a/app/src/main/java/de/danoeh/antennapod/view/viewholder/HorizontalItemViewHolder.java +++ b/app/src/main/java/de/danoeh/antennapod/view/viewholder/HorizontalItemViewHolder.java @@ -14,7 +14,7 @@ import de.danoeh.antennapod.activity.MainActivity; import de.danoeh.antennapod.adapter.CoverLoader; import de.danoeh.antennapod.adapter.actionbutton.ItemActionButton; import de.danoeh.antennapod.core.feed.util.ImageResourceUtils; -import de.danoeh.antennapod.core.util.DateFormatter; +import de.danoeh.antennapod.ui.common.DateFormatter; import de.danoeh.antennapod.core.util.PlaybackStatus; import de.danoeh.antennapod.event.playback.PlaybackPositionEvent; import de.danoeh.antennapod.model.feed.FeedItem; diff --git a/core/build.gradle b/core/build.gradle index 3a0a5e196..6683db189 100644 --- a/core/build.gradle +++ b/core/build.gradle @@ -46,7 +46,6 @@ dependencies { annotationProcessor "androidx.annotation:annotation:$annotationVersion" implementation "androidx.appcompat:appcompat:$appcompatVersion" implementation "androidx.core:core:$coreVersion" - implementation "androidx.core:core-splashscreen:1.0.0" implementation 'androidx.documentfile:documentfile:1.0.1' implementation "androidx.fragment:fragment:$fragmentVersion" implementation "androidx.media:media:$mediaVersion" diff --git a/core/src/main/java/de/danoeh/antennapod/core/service/playback/PlaybackServiceNotificationBuilder.java b/core/src/main/java/de/danoeh/antennapod/core/service/playback/PlaybackServiceNotificationBuilder.java index de57f17df..981757025 100644 --- a/core/src/main/java/de/danoeh/antennapod/core/service/playback/PlaybackServiceNotificationBuilder.java +++ b/core/src/main/java/de/danoeh/antennapod/core/service/playback/PlaybackServiceNotificationBuilder.java @@ -21,7 +21,7 @@ import com.bumptech.glide.request.RequestOptions; import de.danoeh.antennapod.core.R; import de.danoeh.antennapod.storage.preferences.UserPreferences; import de.danoeh.antennapod.core.receiver.MediaButtonReceiver; -import de.danoeh.antennapod.core.util.Converter; +import de.danoeh.antennapod.ui.common.Converter; import de.danoeh.antennapod.core.feed.util.ImageResourceUtils; import de.danoeh.antennapod.core.util.TimeSpeedConverter; import de.danoeh.antennapod.model.playback.Playable; diff --git a/core/src/main/java/de/danoeh/antennapod/core/util/ShareUtils.java b/core/src/main/java/de/danoeh/antennapod/core/util/ShareUtils.java index 630507487..5c8e5d86d 100644 --- a/core/src/main/java/de/danoeh/antennapod/core/util/ShareUtils.java +++ b/core/src/main/java/de/danoeh/antennapod/core/util/ShareUtils.java @@ -9,6 +9,7 @@ import androidx.annotation.NonNull; import androidx.core.app.ShareCompat; import androidx.core.content.FileProvider; +import de.danoeh.antennapod.ui.common.Converter; import java.io.File; import java.net.URLEncoder; diff --git a/core/src/main/java/de/danoeh/antennapod/core/util/gui/ShownotesCleaner.java b/core/src/main/java/de/danoeh/antennapod/core/util/gui/ShownotesCleaner.java index dbb2815e2..7bf9257a1 100644 --- a/core/src/main/java/de/danoeh/antennapod/core/util/gui/ShownotesCleaner.java +++ b/core/src/main/java/de/danoeh/antennapod/core/util/gui/ShownotesCleaner.java @@ -23,7 +23,7 @@ import java.util.regex.Matcher; import java.util.regex.Pattern; import de.danoeh.antennapod.core.R; -import de.danoeh.antennapod.core.util.Converter; +import de.danoeh.antennapod.ui.common.Converter; /** * Cleans up and prepares shownotes: diff --git a/core/src/main/java/de/danoeh/antennapod/core/widget/WidgetUpdater.java b/core/src/main/java/de/danoeh/antennapod/core/widget/WidgetUpdater.java index 3d4cdbcf2..bc1cf8a5e 100644 --- a/core/src/main/java/de/danoeh/antennapod/core/widget/WidgetUpdater.java +++ b/core/src/main/java/de/danoeh/antennapod/core/widget/WidgetUpdater.java @@ -17,6 +17,7 @@ import com.bumptech.glide.load.resource.bitmap.FitCenter; import com.bumptech.glide.load.resource.bitmap.RoundedCorners; import com.bumptech.glide.request.RequestOptions; +import de.danoeh.antennapod.ui.common.Converter; import java.util.concurrent.TimeUnit; import de.danoeh.antennapod.core.R; @@ -24,7 +25,6 @@ import de.danoeh.antennapod.storage.preferences.UserPreferences; import de.danoeh.antennapod.model.playback.MediaType; import de.danoeh.antennapod.core.receiver.MediaButtonReceiver; import de.danoeh.antennapod.core.receiver.PlayerWidget; -import de.danoeh.antennapod.core.util.Converter; import de.danoeh.antennapod.core.feed.util.ImageResourceUtils; import de.danoeh.antennapod.core.util.TimeSpeedConverter; import de.danoeh.antennapod.model.playback.Playable; diff --git a/core/src/test/java/de/danoeh/antennapod/core/feed/FeedFilterTest.java b/core/src/test/java/de/danoeh/antennapod/core/feed/FeedFilterTest.java index c7c47f4fd..cc8e1636c 100644 --- a/core/src/test/java/de/danoeh/antennapod/core/feed/FeedFilterTest.java +++ b/core/src/test/java/de/danoeh/antennapod/core/feed/FeedFilterTest.java @@ -1,6 +1,6 @@ package de.danoeh.antennapod.core.feed; -import de.danoeh.antennapod.core.util.Converter; +import de.danoeh.antennapod.ui.common.Converter; import de.danoeh.antennapod.model.feed.FeedFilter; import de.danoeh.antennapod.model.feed.FeedItem; import de.danoeh.antennapod.model.feed.FeedMedia; diff --git a/core/src/test/java/de/danoeh/antennapod/core/util/ConverterTest.java b/core/src/test/java/de/danoeh/antennapod/core/util/ConverterTest.java index 54e5462d0..2e4ead5e6 100644 --- a/core/src/test/java/de/danoeh/antennapod/core/util/ConverterTest.java +++ b/core/src/test/java/de/danoeh/antennapod/core/util/ConverterTest.java @@ -1,5 +1,6 @@ package de.danoeh.antennapod.core.util; +import de.danoeh.antennapod.ui.common.Converter; import org.junit.Test; import static org.junit.Assert.assertEquals; diff --git a/ui/common/build.gradle b/ui/common/build.gradle index 2771cac72..26db9f9e4 100644 --- a/ui/common/build.gradle +++ b/ui/common/build.gradle @@ -8,10 +8,12 @@ android { } dependencies { + implementation project(":storage:preferences") implementation project(":ui:i18n") annotationProcessor "androidx.annotation:annotation:$annotationVersion" implementation "androidx.appcompat:appcompat:$appcompatVersion" implementation "androidx.viewpager2:viewpager2:$viewPager2Version" implementation "com.google.android.material:material:$googleMaterialVersion" + implementation "androidx.core:core-splashscreen:1.0.0" } diff --git a/core/src/main/java/de/danoeh/antennapod/core/util/Converter.java b/ui/common/src/main/java/de/danoeh/antennapod/ui/common/Converter.java similarity index 98% rename from core/src/main/java/de/danoeh/antennapod/core/util/Converter.java rename to ui/common/src/main/java/de/danoeh/antennapod/ui/common/Converter.java index 30464969b..05fb2dcbc 100644 --- a/core/src/main/java/de/danoeh/antennapod/core/util/Converter.java +++ b/ui/common/src/main/java/de/danoeh/antennapod/ui/common/Converter.java @@ -1,12 +1,10 @@ -package de.danoeh.antennapod.core.util; +package de.danoeh.antennapod.ui.common; import android.content.Context; import android.content.res.Resources; import java.util.Locale; -import de.danoeh.antennapod.core.R; - /** Provides methods for converting various units. */ public final class Converter { /** Class shall not be instantiated. */ diff --git a/core/src/main/java/de/danoeh/antennapod/core/util/DateFormatter.java b/ui/common/src/main/java/de/danoeh/antennapod/ui/common/DateFormatter.java similarity index 96% rename from core/src/main/java/de/danoeh/antennapod/core/util/DateFormatter.java rename to ui/common/src/main/java/de/danoeh/antennapod/ui/common/DateFormatter.java index c67e13db3..1bf4fad23 100644 --- a/core/src/main/java/de/danoeh/antennapod/core/util/DateFormatter.java +++ b/ui/common/src/main/java/de/danoeh/antennapod/ui/common/DateFormatter.java @@ -1,4 +1,4 @@ -package de.danoeh.antennapod.core.util; +package de.danoeh.antennapod.ui.common; import android.content.Context; diff --git a/core/src/main/java/de/danoeh/antennapod/core/preferences/ThemeSwitcher.java b/ui/common/src/main/java/de/danoeh/antennapod/ui/common/ThemeSwitcher.java similarity index 97% rename from core/src/main/java/de/danoeh/antennapod/core/preferences/ThemeSwitcher.java rename to ui/common/src/main/java/de/danoeh/antennapod/ui/common/ThemeSwitcher.java index afe814fcb..9efb4e0f7 100644 --- a/core/src/main/java/de/danoeh/antennapod/core/preferences/ThemeSwitcher.java +++ b/ui/common/src/main/java/de/danoeh/antennapod/ui/common/ThemeSwitcher.java @@ -1,9 +1,8 @@ -package de.danoeh.antennapod.core.preferences; +package de.danoeh.antennapod.ui.common; import android.content.Context; import android.content.res.Configuration; import androidx.annotation.StyleRes; -import de.danoeh.antennapod.core.R; import de.danoeh.antennapod.storage.preferences.UserPreferences; public abstract class ThemeSwitcher { diff --git a/core/src/main/res/color/button_bg_selector.xml b/ui/common/src/main/res/color/button_bg_selector.xml similarity index 100% rename from core/src/main/res/color/button_bg_selector.xml rename to ui/common/src/main/res/color/button_bg_selector.xml diff --git a/core/src/main/res/drawable-nodpi/launcher_animate_bg.png b/ui/common/src/main/res/drawable-nodpi/launcher_animate_bg.png similarity index 100% rename from core/src/main/res/drawable-nodpi/launcher_animate_bg.png rename to ui/common/src/main/res/drawable-nodpi/launcher_animate_bg.png diff --git a/core/src/main/res/drawable-nodpi/launcher_animate_wave1.png b/ui/common/src/main/res/drawable-nodpi/launcher_animate_wave1.png similarity index 100% rename from core/src/main/res/drawable-nodpi/launcher_animate_wave1.png rename to ui/common/src/main/res/drawable-nodpi/launcher_animate_wave1.png diff --git a/core/src/main/res/drawable-nodpi/launcher_animate_wave2.png b/ui/common/src/main/res/drawable-nodpi/launcher_animate_wave2.png similarity index 100% rename from core/src/main/res/drawable-nodpi/launcher_animate_wave2.png rename to ui/common/src/main/res/drawable-nodpi/launcher_animate_wave2.png diff --git a/core/src/main/res/drawable-nodpi/teaser.webp b/ui/common/src/main/res/drawable-nodpi/teaser.webp similarity index 100% rename from core/src/main/res/drawable-nodpi/teaser.webp rename to ui/common/src/main/res/drawable-nodpi/teaser.webp diff --git a/core/src/main/res/drawable/bg_pill_translucent.xml b/ui/common/src/main/res/drawable/bg_pill_translucent.xml similarity index 100% rename from core/src/main/res/drawable/bg_pill_translucent.xml rename to ui/common/src/main/res/drawable/bg_pill_translucent.xml diff --git a/core/src/main/res/drawable/ic_drag_darktheme.xml b/ui/common/src/main/res/drawable/ic_drag_darktheme.xml similarity index 100% rename from core/src/main/res/drawable/ic_drag_darktheme.xml rename to ui/common/src/main/res/drawable/ic_drag_darktheme.xml diff --git a/core/src/main/res/drawable/ic_drag_lighttheme.xml b/ui/common/src/main/res/drawable/ic_drag_lighttheme.xml similarity index 100% rename from core/src/main/res/drawable/ic_drag_lighttheme.xml rename to ui/common/src/main/res/drawable/ic_drag_lighttheme.xml diff --git a/core/src/main/res/drawable/launcher_animate.xml b/ui/common/src/main/res/drawable/launcher_animate.xml similarity index 100% rename from core/src/main/res/drawable/launcher_animate.xml rename to ui/common/src/main/res/drawable/launcher_animate.xml diff --git a/core/src/main/res/drawable/progress_bar_horizontal_dark.xml b/ui/common/src/main/res/drawable/progress_bar_horizontal_dark.xml similarity index 100% rename from core/src/main/res/drawable/progress_bar_horizontal_dark.xml rename to ui/common/src/main/res/drawable/progress_bar_horizontal_dark.xml diff --git a/core/src/main/res/drawable/progress_bar_horizontal_light.xml b/ui/common/src/main/res/drawable/progress_bar_horizontal_light.xml similarity index 100% rename from core/src/main/res/drawable/progress_bar_horizontal_light.xml rename to ui/common/src/main/res/drawable/progress_bar_horizontal_light.xml diff --git a/core/src/main/res/drawable/scrollbar_thumb_dark.xml b/ui/common/src/main/res/drawable/scrollbar_thumb_dark.xml similarity index 100% rename from core/src/main/res/drawable/scrollbar_thumb_dark.xml rename to ui/common/src/main/res/drawable/scrollbar_thumb_dark.xml diff --git a/core/src/main/res/drawable/scrollbar_thumb_default.xml b/ui/common/src/main/res/drawable/scrollbar_thumb_default.xml similarity index 100% rename from core/src/main/res/drawable/scrollbar_thumb_default.xml rename to ui/common/src/main/res/drawable/scrollbar_thumb_default.xml diff --git a/core/src/main/res/drawable/scrollbar_thumb_light.xml b/ui/common/src/main/res/drawable/scrollbar_thumb_light.xml similarity index 100% rename from core/src/main/res/drawable/scrollbar_thumb_light.xml rename to ui/common/src/main/res/drawable/scrollbar_thumb_light.xml diff --git a/core/src/main/res/drawable/scrollbar_thumb_pressed_dark.xml b/ui/common/src/main/res/drawable/scrollbar_thumb_pressed_dark.xml similarity index 100% rename from core/src/main/res/drawable/scrollbar_thumb_pressed_dark.xml rename to ui/common/src/main/res/drawable/scrollbar_thumb_pressed_dark.xml diff --git a/core/src/main/res/drawable/scrollbar_thumb_pressed_light.xml b/ui/common/src/main/res/drawable/scrollbar_thumb_pressed_light.xml similarity index 100% rename from core/src/main/res/drawable/scrollbar_thumb_pressed_light.xml rename to ui/common/src/main/res/drawable/scrollbar_thumb_pressed_light.xml diff --git a/core/src/main/res/drawable/scrollbar_track.xml b/ui/common/src/main/res/drawable/scrollbar_track.xml similarity index 100% rename from core/src/main/res/drawable/scrollbar_track.xml rename to ui/common/src/main/res/drawable/scrollbar_track.xml diff --git a/core/src/main/res/layout/preference_material_switch.xml b/ui/common/src/main/res/layout/preference_material_switch.xml similarity index 100% rename from core/src/main/res/layout/preference_material_switch.xml rename to ui/common/src/main/res/layout/preference_material_switch.xml diff --git a/core/src/main/res/mipmap-anydpi-v26/ic_launcher.xml b/ui/common/src/main/res/mipmap-anydpi-v26/ic_launcher.xml similarity index 100% rename from core/src/main/res/mipmap-anydpi-v26/ic_launcher.xml rename to ui/common/src/main/res/mipmap-anydpi-v26/ic_launcher.xml diff --git a/core/src/main/res/mipmap-hdpi/ic_launcher.png b/ui/common/src/main/res/mipmap-hdpi/ic_launcher.png similarity index 100% rename from core/src/main/res/mipmap-hdpi/ic_launcher.png rename to ui/common/src/main/res/mipmap-hdpi/ic_launcher.png diff --git a/core/src/main/res/mipmap-hdpi/ic_launcher_background.png b/ui/common/src/main/res/mipmap-hdpi/ic_launcher_background.png similarity index 100% rename from core/src/main/res/mipmap-hdpi/ic_launcher_background.png rename to ui/common/src/main/res/mipmap-hdpi/ic_launcher_background.png diff --git a/core/src/main/res/mipmap-hdpi/ic_launcher_foreground.png b/ui/common/src/main/res/mipmap-hdpi/ic_launcher_foreground.png similarity index 100% rename from core/src/main/res/mipmap-hdpi/ic_launcher_foreground.png rename to ui/common/src/main/res/mipmap-hdpi/ic_launcher_foreground.png diff --git a/core/src/main/res/mipmap-mdpi/ic_launcher.png b/ui/common/src/main/res/mipmap-mdpi/ic_launcher.png similarity index 100% rename from core/src/main/res/mipmap-mdpi/ic_launcher.png rename to ui/common/src/main/res/mipmap-mdpi/ic_launcher.png diff --git a/core/src/main/res/mipmap-mdpi/ic_launcher_background.png b/ui/common/src/main/res/mipmap-mdpi/ic_launcher_background.png similarity index 100% rename from core/src/main/res/mipmap-mdpi/ic_launcher_background.png rename to ui/common/src/main/res/mipmap-mdpi/ic_launcher_background.png diff --git a/core/src/main/res/mipmap-mdpi/ic_launcher_foreground.png b/ui/common/src/main/res/mipmap-mdpi/ic_launcher_foreground.png similarity index 100% rename from core/src/main/res/mipmap-mdpi/ic_launcher_foreground.png rename to ui/common/src/main/res/mipmap-mdpi/ic_launcher_foreground.png diff --git a/core/src/main/res/mipmap-xhdpi/ic_launcher.png b/ui/common/src/main/res/mipmap-xhdpi/ic_launcher.png similarity index 100% rename from core/src/main/res/mipmap-xhdpi/ic_launcher.png rename to ui/common/src/main/res/mipmap-xhdpi/ic_launcher.png diff --git a/core/src/main/res/mipmap-xhdpi/ic_launcher_background.png b/ui/common/src/main/res/mipmap-xhdpi/ic_launcher_background.png similarity index 100% rename from core/src/main/res/mipmap-xhdpi/ic_launcher_background.png rename to ui/common/src/main/res/mipmap-xhdpi/ic_launcher_background.png diff --git a/core/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png b/ui/common/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png similarity index 100% rename from core/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png rename to ui/common/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png diff --git a/core/src/main/res/mipmap-xxhdpi/ic_launcher.png b/ui/common/src/main/res/mipmap-xxhdpi/ic_launcher.png similarity index 100% rename from core/src/main/res/mipmap-xxhdpi/ic_launcher.png rename to ui/common/src/main/res/mipmap-xxhdpi/ic_launcher.png diff --git a/core/src/main/res/mipmap-xxhdpi/ic_launcher_background.png b/ui/common/src/main/res/mipmap-xxhdpi/ic_launcher_background.png similarity index 100% rename from core/src/main/res/mipmap-xxhdpi/ic_launcher_background.png rename to ui/common/src/main/res/mipmap-xxhdpi/ic_launcher_background.png diff --git a/core/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png b/ui/common/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png similarity index 100% rename from core/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png rename to ui/common/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png diff --git a/core/src/main/res/mipmap-xxxhdpi/ic_launcher.png b/ui/common/src/main/res/mipmap-xxxhdpi/ic_launcher.png similarity index 100% rename from core/src/main/res/mipmap-xxxhdpi/ic_launcher.png rename to ui/common/src/main/res/mipmap-xxxhdpi/ic_launcher.png diff --git a/core/src/main/res/mipmap-xxxhdpi/ic_launcher_background.png b/ui/common/src/main/res/mipmap-xxxhdpi/ic_launcher_background.png similarity index 100% rename from core/src/main/res/mipmap-xxxhdpi/ic_launcher_background.png rename to ui/common/src/main/res/mipmap-xxxhdpi/ic_launcher_background.png diff --git a/core/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png b/ui/common/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png similarity index 100% rename from core/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png rename to ui/common/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png diff --git a/core/src/main/res/mipmap-xxxhdpi/ic_launcher_monochrome.png b/ui/common/src/main/res/mipmap-xxxhdpi/ic_launcher_monochrome.png similarity index 100% rename from core/src/main/res/mipmap-xxxhdpi/ic_launcher_monochrome.png rename to ui/common/src/main/res/mipmap-xxxhdpi/ic_launcher_monochrome.png diff --git a/core/src/main/res/values-v23/styles.xml b/ui/common/src/main/res/values-v23/styles.xml similarity index 100% rename from core/src/main/res/values-v23/styles.xml rename to ui/common/src/main/res/values-v23/styles.xml diff --git a/core/src/main/res/values-v27/styles.xml b/ui/common/src/main/res/values-v27/styles.xml similarity index 100% rename from core/src/main/res/values-v27/styles.xml rename to ui/common/src/main/res/values-v27/styles.xml diff --git a/core/src/main/res/values/attrs.xml b/ui/common/src/main/res/values/attrs.xml similarity index 100% rename from core/src/main/res/values/attrs.xml rename to ui/common/src/main/res/values/attrs.xml diff --git a/core/src/main/res/values/colors.xml b/ui/common/src/main/res/values/colors.xml similarity index 100% rename from core/src/main/res/values/colors.xml rename to ui/common/src/main/res/values/colors.xml diff --git a/core/src/main/res/values/dimens.xml b/ui/common/src/main/res/values/dimens.xml similarity index 100% rename from core/src/main/res/values/dimens.xml rename to ui/common/src/main/res/values/dimens.xml diff --git a/core/src/main/res/values/styles.xml b/ui/common/src/main/res/values/styles.xml similarity index 100% rename from core/src/main/res/values/styles.xml rename to ui/common/src/main/res/values/styles.xml diff --git a/ui/echo/build.gradle b/ui/echo/build.gradle index de949d18b..cddec6e8f 100644 --- a/ui/echo/build.gradle +++ b/ui/echo/build.gradle @@ -16,6 +16,7 @@ dependencies { implementation project(":core") implementation project(":model") implementation project(":storage:preferences") + implementation project(':ui:common') implementation project(':ui:glide') annotationProcessor "androidx.annotation:annotation:$annotationVersion" diff --git a/ui/echo/src/main/java/de/danoeh/antennapod/ui/echo/EchoActivity.java b/ui/echo/src/main/java/de/danoeh/antennapod/ui/echo/EchoActivity.java index 5981c7ad4..5e88f175d 100644 --- a/ui/echo/src/main/java/de/danoeh/antennapod/ui/echo/EchoActivity.java +++ b/ui/echo/src/main/java/de/danoeh/antennapod/ui/echo/EchoActivity.java @@ -26,9 +26,9 @@ import com.bumptech.glide.request.RequestOptions; import de.danoeh.antennapod.core.feed.util.PlaybackSpeedUtils; import de.danoeh.antennapod.core.storage.DBReader; import de.danoeh.antennapod.core.storage.StatisticsItem; -import de.danoeh.antennapod.core.util.Converter; import de.danoeh.antennapod.model.feed.FeedItem; import de.danoeh.antennapod.storage.preferences.UserPreferences; +import de.danoeh.antennapod.ui.common.Converter; import de.danoeh.antennapod.ui.echo.databinding.EchoActivityBinding; import de.danoeh.antennapod.ui.echo.screens.BubbleScreen; import de.danoeh.antennapod.ui.echo.screens.FinalShareScreen; diff --git a/ui/statistics/src/main/java/de/danoeh/antennapod/ui/statistics/feed/FeedStatisticsFragment.java b/ui/statistics/src/main/java/de/danoeh/antennapod/ui/statistics/feed/FeedStatisticsFragment.java index a7916ac5a..1e2520953 100644 --- a/ui/statistics/src/main/java/de/danoeh/antennapod/ui/statistics/feed/FeedStatisticsFragment.java +++ b/ui/statistics/src/main/java/de/danoeh/antennapod/ui/statistics/feed/FeedStatisticsFragment.java @@ -11,8 +11,8 @@ import androidx.annotation.Nullable; import androidx.fragment.app.Fragment; import de.danoeh.antennapod.core.storage.DBReader; import de.danoeh.antennapod.core.storage.StatisticsItem; -import de.danoeh.antennapod.core.util.Converter; -import de.danoeh.antennapod.core.util.DateFormatter; +import de.danoeh.antennapod.ui.common.Converter; +import de.danoeh.antennapod.ui.common.DateFormatter; import de.danoeh.antennapod.core.util.ReleaseScheduleGuesser; import de.danoeh.antennapod.model.feed.FeedItem; import de.danoeh.antennapod.model.feed.FeedItemFilter; diff --git a/ui/statistics/src/main/java/de/danoeh/antennapod/ui/statistics/subscriptions/PlaybackStatisticsListAdapter.java b/ui/statistics/src/main/java/de/danoeh/antennapod/ui/statistics/subscriptions/PlaybackStatisticsListAdapter.java index 9b1f234c8..55e6cc0fd 100644 --- a/ui/statistics/src/main/java/de/danoeh/antennapod/ui/statistics/subscriptions/PlaybackStatisticsListAdapter.java +++ b/ui/statistics/src/main/java/de/danoeh/antennapod/ui/statistics/subscriptions/PlaybackStatisticsListAdapter.java @@ -3,7 +3,7 @@ package de.danoeh.antennapod.ui.statistics.subscriptions; import android.text.format.DateFormat; import androidx.fragment.app.Fragment; import de.danoeh.antennapod.core.storage.StatisticsItem; -import de.danoeh.antennapod.core.util.Converter; +import de.danoeh.antennapod.ui.common.Converter; import de.danoeh.antennapod.ui.statistics.PieChartView; import de.danoeh.antennapod.ui.statistics.R; import de.danoeh.antennapod.ui.statistics.StatisticsListAdapter; diff --git a/ui/widget/build.gradle b/ui/widget/build.gradle index f474b0028..2488054a6 100644 --- a/ui/widget/build.gradle +++ b/ui/widget/build.gradle @@ -13,5 +13,7 @@ android { } dependencies { + implementation project(":ui:common") + annotationProcessor "androidx.annotation:annotation:$annotationVersion" }