summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--app/build.gradle4
-rw-r--r--app/src/androidTest/java/de/test/antennapod/EspressoTestUtils.java2
-rw-r--r--app/src/androidTest/java/de/test/antennapod/dialogs/ShareDialogTest.java2
-rw-r--r--app/src/androidTest/java/de/test/antennapod/ui/NavigationDrawerTest.java12
-rw-r--r--app/src/androidTest/java/de/test/antennapod/ui/PreferencesTest.java2
-rw-r--r--app/src/androidTest/java/de/test/antennapod/ui/QueueFragmentTest.java2
-rw-r--r--app/src/main/AndroidManifest.xml31
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ClientConfigurator.java2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/CrashReportWriter.java (renamed from app/src/main/java/de/danoeh/antennapod/error/CrashReportWriter.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/PodcastApp.java24
-rw-r--r--app/src/main/java/de/danoeh/antennapod/PreferenceUpgrader.java (renamed from app/src/main/java/de/danoeh/antennapod/preferences/PreferenceUpgrader.java)12
-rw-r--r--app/src/main/java/de/danoeh/antennapod/RxJavaErrorHandlerSetup.java (renamed from app/src/main/java/de/danoeh/antennapod/error/RxJavaErrorHandlerSetup.java)3
-rw-r--r--app/src/main/java/de/danoeh/antennapod/actionbutton/CancelDownloadActionButton.java (renamed from app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/CancelDownloadActionButton.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/actionbutton/DeleteActionButton.java (renamed from app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/DeleteActionButton.java)4
-rw-r--r--app/src/main/java/de/danoeh/antennapod/actionbutton/DownloadActionButton.java (renamed from app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/DownloadActionButton.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/actionbutton/ItemActionButton.java (renamed from app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/ItemActionButton.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/actionbutton/MarkAsPlayedActionButton.java (renamed from app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/MarkAsPlayedActionButton.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/actionbutton/PauseActionButton.java (renamed from app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/PauseActionButton.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/actionbutton/PlayActionButton.java (renamed from app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/PlayActionButton.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/actionbutton/PlayLocalActionButton.java (renamed from app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/PlayLocalActionButton.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/actionbutton/StreamActionButton.java (renamed from app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/StreamActionButton.java)4
-rw-r--r--app/src/main/java/de/danoeh/antennapod/actionbutton/VisitWebsiteActionButton.java (renamed from app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/VisitWebsiteActionButton.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/activity/MainActivity.java32
-rw-r--r--app/src/main/java/de/danoeh/antennapod/activity/SplashActivity.java2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/receiver/ConnectivityActionReceiver.java25
-rw-r--r--app/src/main/java/de/danoeh/antennapod/spa/SPAReceiver.java (renamed from app/src/main/java/de/danoeh/antennapod/receiver/SPAReceiver.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/spa/SPAUtil.java1
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/AllEpisodesFilterDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/AllEpisodesFilterDialog.java)5
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/CoverLoader.java (renamed from app/src/main/java/de/danoeh/antennapod/adapter/CoverLoader.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/FeedItemFilterDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/FeedItemFilterDialog.java)5
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/MenuItemUtils.java (renamed from core/src/main/java/de/danoeh/antennapod/core/menuhandler/MenuItemUtils.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/SelectableAdapter.java (renamed from app/src/main/java/de/danoeh/antennapod/adapter/SelectableAdapter.java)6
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/SimpleChipAdapter.java (renamed from app/src/main/java/de/danoeh/antennapod/adapter/SimpleChipAdapter.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/StreamingConfirmationDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/StreamingConfirmationDialog.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/TransitionEffect.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/TransitionEffect.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/cleaner/HtmlToPlainText.java (renamed from core/src/main/java/de/danoeh/antennapod/core/util/syndication/HtmlToPlainText.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/cleaner/ShownotesCleaner.java (renamed from core/src/main/java/de/danoeh/antennapod/core/util/gui/ShownotesCleaner.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/episodeslist/EpisodeItemListAdapter.java (renamed from app/src/main/java/de/danoeh/antennapod/adapter/EpisodeItemListAdapter.java)7
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/episodeslist/EpisodeItemListRecyclerView.java (renamed from app/src/main/java/de/danoeh/antennapod/view/EpisodeItemListRecyclerView.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/episodeslist/EpisodeItemViewHolder.java (renamed from app/src/main/java/de/danoeh/antennapod/view/viewholder/EpisodeItemViewHolder.java)7
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/episodeslist/EpisodeMultiSelectActionHandler.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/actions/EpisodeMultiSelectActionHandler.java)4
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/episodeslist/EpisodesListFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/EpisodesListFragment.java)38
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/episodeslist/FeedItemMenuHandler.java (renamed from app/src/main/java/de/danoeh/antennapod/menuhandler/FeedItemMenuHandler.java)8
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/episodeslist/HorizontalItemListAdapter.java (renamed from app/src/main/java/de/danoeh/antennapod/adapter/HorizontalItemListAdapter.java)6
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/episodeslist/HorizontalItemViewHolder.java (renamed from app/src/main/java/de/danoeh/antennapod/view/viewholder/HorizontalItemViewHolder.java)6
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/episodeslist/MediaSizeLoader.java (renamed from core/src/main/java/de/danoeh/antennapod/core/util/download/MediaSizeLoader.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/episodeslist/MoreContentListFooterUtil.java (renamed from core/src/main/java/de/danoeh/antennapod/core/util/gui/MoreContentListFooterUtil.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/AddFeedFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/AddFeedFragment.java)3
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/AllEpisodesFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/AllEpisodesFragment.java)7
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/InboxFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/InboxFragment.java)5
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/PlaybackHistoryFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/PlaybackHistoryFragment.java)5
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/SearchFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/SearchFragment.java)22
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/chapter/ChaptersFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/ChaptersFragment.java)3
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/chapter/ChaptersListAdapter.java (renamed from app/src/main/java/de/danoeh/antennapod/adapter/ChaptersListAdapter.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/download/CompletedDownloadsFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/CompletedDownloadsFragment.java)25
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/download/DownloadErrorLabel.java (renamed from core/src/main/java/de/danoeh/antennapod/core/util/DownloadErrorLabel.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/download/DownloadLogAdapter.java (renamed from app/src/main/java/de/danoeh/antennapod/adapter/DownloadLogAdapter.java)6
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/download/DownloadLogDetailsDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/DownloadLogDetailsDialog.java)3
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/download/DownloadLogFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/DownloadLogFragment.java)6
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/download/DownloadLogItemViewHolder.java (renamed from app/src/main/java/de/danoeh/antennapod/view/viewholder/DownloadLogItemViewHolder.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/drawer/DrawerPreferencesDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/DrawerPreferencesDialog.java)4
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/drawer/NavDrawerFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/NavDrawerFragment.java)31
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/drawer/NavListAdapter.java (renamed from app/src/main/java/de/danoeh/antennapod/adapter/NavListAdapter.java)21
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/episode/ItemFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/ItemFragment.java)27
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/episode/ItemPagerFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/ItemPagerFragment.java)5
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/feed/FeedInfoFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/FeedInfoFragment.java)10
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/feed/FeedItemFilterGroup.java (renamed from core/src/main/java/de/danoeh/antennapod/core/feed/FeedItemFilterGroup.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/feed/FeedItemlistFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/FeedItemlistFragment.java)33
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/feed/ItemFilterDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/ItemFilterDialog.java)5
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/feed/ItemSortDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/ItemSortDialog.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/feed/RemoveFeedDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/RemoveFeedDialog.java)4
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/feed/RenameFeedDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/RenameItemDialog.java)8
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/feed/ToolbarIconTintManager.java (renamed from app/src/main/java/de/danoeh/antennapod/view/ToolbarIconTintManager.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/feed/preferences/EditUrlSettingsDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/EditUrlSettingsDialog.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/feed/preferences/EpisodeFilterDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/EpisodeFilterDialog.java)6
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/feed/preferences/FeedPreferenceSkipDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/FeedPreferenceSkipDialog.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/feed/preferences/FeedSettingsFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/FeedSettingsFragment.java)5
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/feed/preferences/SkipPreferenceDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/SkipPreferenceDialog.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/feed/preferences/TagSettingsDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/TagSettingsDialog.java)6
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/feed/preferences/VolumeAdaptationPreference.java (renamed from app/src/main/java/de/danoeh/antennapod/preferences/VolumeAdaptationPreference.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/home/HomeFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/ui/home/HomeFragment.java)20
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/home/HomeSection.java (renamed from app/src/main/java/de/danoeh/antennapod/ui/home/HomeSection.java)12
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/home/HomeSectionsSettingsDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/ui/home/HomeSectionsSettingsDialog.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/home/sections/AllowNotificationsSection.java (renamed from app/src/main/java/de/danoeh/antennapod/ui/home/sections/AllowNotificationsSection.java)4
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/home/sections/DownloadsSection.java (renamed from app/src/main/java/de/danoeh/antennapod/ui/home/sections/DownloadsSection.java)14
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/home/sections/EchoSection.java (renamed from app/src/main/java/de/danoeh/antennapod/ui/home/sections/EchoSection.java)4
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/home/sections/EpisodesSurpriseSection.java (renamed from app/src/main/java/de/danoeh/antennapod/ui/home/sections/EpisodesSurpriseSection.java)12
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/home/sections/InboxSection.java (renamed from app/src/main/java/de/danoeh/antennapod/ui/home/sections/InboxSection.java)12
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/home/sections/QueueSection.java (renamed from app/src/main/java/de/danoeh/antennapod/ui/home/sections/QueueSection.java)12
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/home/sections/SubscriptionsSection.java (renamed from app/src/main/java/de/danoeh/antennapod/ui/home/sections/SubscriptionsSection.java)10
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/onlinefeedview/FeedDiscoverer.java (renamed from core/src/main/java/de/danoeh/antennapod/core/util/syndication/FeedDiscoverer.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/onlinefeedview/FeedItemlistDescriptionAdapter.java (renamed from app/src/main/java/de/danoeh/antennapod/adapter/FeedItemlistDescriptionAdapter.java)6
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/onlinefeedview/OnlineFeedViewActivity.java (renamed from app/src/main/java/de/danoeh/antennapod/activity/OnlineFeedViewActivity.java)8
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/playback/MediaPlayerErrorDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/MediaPlayerErrorDialog.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/playback/PlayButton.java (renamed from app/src/main/java/de/danoeh/antennapod/view/PlayButton.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/playback/PlaybackControlsDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/PlaybackControlsDialog.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/playback/PlaybackSpeedDialogActivity.java (renamed from app/src/main/java/de/danoeh/antennapod/activity/PlaybackSpeedDialogActivity.java)4
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/playback/PlaybackSpeedSeekBar.java (renamed from app/src/main/java/de/danoeh/antennapod/view/PlaybackSpeedSeekBar.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/playback/SleepTimerDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/SleepTimerDialog.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/playback/TimeRangeDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/TimeRangeDialog.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/playback/VariableSpeedDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/VariableSpeedDialog.java)5
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/playback/audio/AudioPlayerFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/AudioPlayerFragment.java)15
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/playback/audio/ChapterSeekBar.java (renamed from app/src/main/java/de/danoeh/antennapod/view/ChapterSeekBar.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/playback/audio/CoverFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/CoverFragment.java)3
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/playback/audio/ExternalPlayerFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/ExternalPlayerFragment.java)4
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/playback/audio/ItemDescriptionFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/ItemDescriptionFragment.java)6
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/playback/audio/NoRelayoutTextView.java (renamed from app/src/main/java/de/danoeh/antennapod/view/NoRelayoutTextView.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/playback/video/AspectRatioVideoView.java (renamed from app/src/main/java/de/danoeh/antennapod/view/AspectRatioVideoView.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/playback/video/PictureInPictureUtil.java (renamed from core/src/main/java/de/danoeh/antennapod/core/util/gui/PictureInPictureUtil.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/playback/video/VideoplayerActivity.java (renamed from app/src/main/java/de/danoeh/antennapod/activity/VideoplayerActivity.java)20
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/BugReportActivity.java (renamed from app/src/main/java/de/danoeh/antennapod/activity/BugReportActivity.java)4
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/DownloadsPreferencesFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/preferences/DownloadsPreferencesFragment.java)4
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/ImportExportPreferencesFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/preferences/ImportExportPreferencesFragment.java)3
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/MainPreferencesFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/preferences/MainPreferencesFragment.java)4
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/PlaybackPreferencesFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/preferences/PlaybackPreferencesFragment.java)7
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/PreferenceActivity.java (renamed from app/src/main/java/de/danoeh/antennapod/activity/PreferenceActivity.java)8
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/PreferenceListDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/preferences/dialog/PreferenceListDialog.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/PreferenceSwitchDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/preferences/dialog/PreferenceSwitchDialog.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/ProxyDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/ProxyDialog.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/SwipePreferencesFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/preferences/SwipePreferencesFragment.java)17
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/UserInterfacePreferencesFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/preferences/UserInterfacePreferencesFragment.java)9
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/queue/QueueFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/QueueFragment.java)26
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/queue/QueueRecyclerAdapter.java (renamed from app/src/main/java/de/danoeh/antennapod/adapter/QueueRecyclerAdapter.java)7
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/rating/RatingDialogFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/rating/RatingDialogFragment.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/rating/RatingDialogManager.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/rating/RatingDialogManager.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/FeedMenuHandler.java (renamed from app/src/main/java/de/danoeh/antennapod/menuhandler/FeedMenuHandler.java)14
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/FeedMultiSelectActionHandler.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/actions/FeedMultiSelectActionHandler.java)10
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/FeedSortDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/FeedSortDialog.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/HorizontalFeedListAdapter.java (renamed from app/src/main/java/de/danoeh/antennapod/adapter/HorizontalFeedListAdapter.java)4
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/SubscriptionFragment.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/SubscriptionFragment.java)19
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/SubscriptionsFilterDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/SubscriptionsFilterDialog.java)3
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/SubscriptionsFilterGroup.java (renamed from core/src/main/java/de/danoeh/antennapod/core/feed/SubscriptionsFilterGroup.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/SubscriptionsRecyclerAdapter.java (renamed from app/src/main/java/de/danoeh/antennapod/adapter/SubscriptionsRecyclerAdapter.java)7
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/share/ShareDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/ShareDialog.java)3
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/share/ShareUtils.java (renamed from core/src/main/java/de/danoeh/antennapod/core/util/ShareUtils.java)3
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/swipeactions/AddToQueueSwipeAction.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/AddToQueueSwipeAction.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/swipeactions/DeleteSwipeAction.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/DeleteSwipeAction.java)4
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/swipeactions/MarkFavoriteSwipeAction.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/MarkFavoriteSwipeAction.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/swipeactions/RemoveFromHistorySwipeAction.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/RemoveFromHistorySwipeAction.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/swipeactions/RemoveFromInboxSwipeAction.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/RemoveFromInboxSwipeAction.java)4
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/swipeactions/RemoveFromQueueSwipeAction.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/RemoveFromQueueSwipeAction.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/swipeactions/ShowFirstSwipeDialogAction.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/ShowFirstSwipeDialogAction.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/swipeactions/StartDownloadSwipeAction.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/StartDownloadSwipeAction.java)4
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/swipeactions/SwipeAction.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/SwipeAction.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/swipeactions/SwipeActions.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/SwipeActions.java)15
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/swipeactions/SwipeActionsDialog.java (renamed from app/src/main/java/de/danoeh/antennapod/dialog/SwipeActionsDialog.java)24
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/swipeactions/TogglePlaybackStateSwipeAction.java (renamed from app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/TogglePlaybackStateSwipeAction.java)4
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/view/EmptyViewHandler.java (renamed from app/src/main/java/de/danoeh/antennapod/view/EmptyViewHandler.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/view/ItemOffsetDecoration.java (renamed from app/src/main/java/de/danoeh/antennapod/view/ItemOffsetDecoration.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/view/LiftOnScrollListener.java (renamed from app/src/main/java/de/danoeh/antennapod/view/LiftOnScrollListener.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/view/LocalDeleteModal.java (renamed from app/src/main/java/de/danoeh/antennapod/view/LocalDeleteModal.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/view/LockableBottomSheetBehavior.java (renamed from app/src/main/java/de/danoeh/antennapod/view/LockableBottomSheetBehavior.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/view/NestedScrollableHost.java (renamed from app/src/main/java/de/danoeh/antennapod/view/NestedScrollableHost.java)2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/view/ShownotesWebView.java (renamed from app/src/main/java/de/danoeh/antennapod/view/ShownotesWebView.java)8
-rw-r--r--app/src/main/java/de/danoeh/antennapod/ui/view/SimpleAdapterDataObserver.java (renamed from app/src/main/java/de/danoeh/antennapod/view/SimpleAdapterDataObserver.java)2
-rw-r--r--app/src/main/res/layout-sw720dp/main.xml2
-rw-r--r--app/src/main/res/layout/audioplayer_fragment.xml8
-rw-r--r--app/src/main/res/layout/episodes_list_fragment.xml2
-rw-r--r--app/src/main/res/layout/external_player_fragment.xml2
-rw-r--r--app/src/main/res/layout/feed_item_list_fragment.xml2
-rw-r--r--app/src/main/res/layout/feeditem_fragment.xml6
-rw-r--r--app/src/main/res/layout/item_description_fragment.xml15
-rw-r--r--app/src/main/res/layout/main.xml2
-rw-r--r--app/src/main/res/layout/playback_speed_feed_setting_dialog.xml2
-rw-r--r--app/src/main/res/layout/queue_fragment.xml2
-rw-r--r--app/src/main/res/layout/search_fragment.xml2
-rw-r--r--app/src/main/res/layout/simple_list_fragment.xml2
-rw-r--r--app/src/main/res/layout/speed_select_dialog.xml2
-rw-r--r--app/src/main/res/layout/videoplayer_activity.xml19
-rw-r--r--app/src/main/res/xml/feed_settings.xml2
-rw-r--r--app/src/test/java/de/danoeh/antennapod/ui/cleaner/ShownotesCleanerTest.java (renamed from core/src/test/java/de/danoeh/antennapod/core/util/gui/ShownotesCleanerTest.java)2
-rw-r--r--app/src/test/java/de/danoeh/antennapod/ui/screen/onlinefeedview/FeedDiscovererTest.java (renamed from core/src/test/java/de/danoeh/antennapod/core/util/syndication/FeedDiscovererTest.java)2
-rw-r--r--config/spotbugs/exclude.xml6
-rw-r--r--core/src/main/java/de/danoeh/antennapod/core/storage/AutomaticDownloadAlgorithm.java21
-rw-r--r--core/src/main/java/de/danoeh/antennapod/core/util/ChapterMerger.java (renamed from core/src/main/java/de/danoeh/antennapod/core/feed/ChapterMerger.java)2
-rw-r--r--core/src/main/java/de/danoeh/antennapod/core/util/ChapterUtils.java1
-rw-r--r--core/src/main/java/de/danoeh/antennapod/core/util/ConfirmationDialog.java (renamed from core/src/main/java/de/danoeh/antennapod/core/dialog/ConfirmationDialog.java)2
-rw-r--r--core/src/main/java/de/danoeh/antennapod/core/util/PowerUtils.java30
-rw-r--r--core/src/main/java/de/danoeh/antennapod/core/util/download/NetworkConnectionChangeHandler.java29
-rw-r--r--core/src/test/java/android/text/TextUtils.java42
-rw-r--r--model/build.gradle4
-rw-r--r--model/src/main/java/de/danoeh/antennapod/model/feed/Feed.java9
-rw-r--r--model/src/main/java/de/danoeh/antennapod/model/playback/RemoteMedia.java16
-rw-r--r--model/src/test/java/de/danoeh/antennapod/model/VolumeAdaptionSettingTest.java (renamed from core/src/test/java/de/danoeh/antennapod/core/feed/VolumeAdaptionSettingTest.java)6
-rw-r--r--net/download/service-interface/src/test/java/de/danoeh/antennapod/net/download/serviceinterface/FilenameGeneratorTest.java (renamed from core/src/test/java/de/danoeh/antennapod/core/util/FilenameGeneratorTest.java)3
-rw-r--r--net/download/service/src/main/AndroidManifest.xml18
-rw-r--r--net/download/service/src/main/java/de/danoeh/antennapod/net/download/service/ConnectivityActionReceiver.java34
-rw-r--r--net/download/service/src/main/java/de/danoeh/antennapod/net/download/service/PowerConnectionReceiver.java (renamed from app/src/main/java/de/danoeh/antennapod/receiver/PowerConnectionReceiver.java)4
-rw-r--r--storage/database/build.gradle3
-rw-r--r--storage/database/src/main/java/de/danoeh/antennapod/storage/database/FeedItemDuplicateGuesser.java8
-rw-r--r--storage/database/src/test/java/de/danoeh/antennapod/storage/database/FeedItemPermutorsTest.java (renamed from core/src/test/java/de/danoeh/antennapod/core/util/FeedItemPermutorsTest.java)2
-rw-r--r--storage/database/src/test/java/de/danoeh/antennapod/storage/database/mapper/FeedCursorMapperTest.java (renamed from core/src/test/java/de/danoeh/antennapod/core/storage/mapper/FeedCursorMapperTest.java)3
-rw-r--r--ui/common/build.gradle2
-rw-r--r--ui/common/src/test/java/de/danoeh/antennapod/ui/common/ConverterTest.java (renamed from core/src/test/java/de/danoeh/antennapod/core/util/ConverterTest.java)2
-rw-r--r--ui/statistics/src/main/java/de/danoeh/antennapod/ui/statistics/StatisticsFragment.java2
195 files changed, 616 insertions, 723 deletions
diff --git a/app/build.gradle b/app/build.gradle
index a07d0db4a..449488f58 100644
--- a/app/build.gradle
+++ b/app/build.gradle
@@ -122,6 +122,10 @@ dependencies {
implementation 'com.github.skydoves:balloon:1.5.3'
implementation 'com.github.xabaras:RecyclerViewSwipeDecorator:1.3'
+ testImplementation "androidx.test:core:$testCoreVersion"
+ testImplementation "junit:junit:$junitVersion"
+ testImplementation "org.robolectric:robolectric:$robolectricVersion"
+
androidTestImplementation "org.awaitility:awaitility:$awaitilityVersion"
androidTestImplementation 'com.nanohttpd:nanohttpd:2.1.1'
androidTestImplementation "androidx.test.espresso:espresso-core:$espressoVersion"
diff --git a/app/src/androidTest/java/de/test/antennapod/EspressoTestUtils.java b/app/src/androidTest/java/de/test/antennapod/EspressoTestUtils.java
index 041106017..c52df7f3e 100644
--- a/app/src/androidTest/java/de/test/antennapod/EspressoTestUtils.java
+++ b/app/src/androidTest/java/de/test/antennapod/EspressoTestUtils.java
@@ -25,7 +25,7 @@ import junit.framework.AssertionFailedError;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
-import de.danoeh.antennapod.fragment.NavDrawerFragment;
+import de.danoeh.antennapod.ui.screen.drawer.NavDrawerFragment;
import org.awaitility.Awaitility;
import org.awaitility.core.ConditionTimeoutException;
import org.hamcrest.Matcher;
diff --git a/app/src/androidTest/java/de/test/antennapod/dialogs/ShareDialogTest.java b/app/src/androidTest/java/de/test/antennapod/dialogs/ShareDialogTest.java
index 58a4a0bb6..2afe196b1 100644
--- a/app/src/androidTest/java/de/test/antennapod/dialogs/ShareDialogTest.java
+++ b/app/src/androidTest/java/de/test/antennapod/dialogs/ShareDialogTest.java
@@ -8,7 +8,7 @@ import androidx.test.ext.junit.runners.AndroidJUnit4;
import androidx.test.platform.app.InstrumentationRegistry;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
-import de.danoeh.antennapod.fragment.AllEpisodesFragment;
+import de.danoeh.antennapod.ui.screen.AllEpisodesFragment;
import de.test.antennapod.EspressoTestUtils;
import de.test.antennapod.ui.UITestUtils;
import org.hamcrest.Matcher;
diff --git a/app/src/androidTest/java/de/test/antennapod/ui/NavigationDrawerTest.java b/app/src/androidTest/java/de/test/antennapod/ui/NavigationDrawerTest.java
index 5ccb35228..0246cf890 100644
--- a/app/src/androidTest/java/de/test/antennapod/ui/NavigationDrawerTest.java
+++ b/app/src/androidTest/java/de/test/antennapod/ui/NavigationDrawerTest.java
@@ -7,14 +7,14 @@ import androidx.test.espresso.intent.rule.IntentsTestRule;
import androidx.test.ext.junit.runners.AndroidJUnit4;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
-import de.danoeh.antennapod.activity.PreferenceActivity;
-import de.danoeh.antennapod.fragment.CompletedDownloadsFragment;
+import de.danoeh.antennapod.ui.screen.preferences.PreferenceActivity;
+import de.danoeh.antennapod.ui.screen.download.CompletedDownloadsFragment;
import de.danoeh.antennapod.model.feed.Feed;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
-import de.danoeh.antennapod.fragment.AllEpisodesFragment;
-import de.danoeh.antennapod.fragment.NavDrawerFragment;
-import de.danoeh.antennapod.fragment.PlaybackHistoryFragment;
-import de.danoeh.antennapod.fragment.QueueFragment;
+import de.danoeh.antennapod.ui.screen.AllEpisodesFragment;
+import de.danoeh.antennapod.ui.screen.drawer.NavDrawerFragment;
+import de.danoeh.antennapod.ui.screen.PlaybackHistoryFragment;
+import de.danoeh.antennapod.ui.screen.queue.QueueFragment;
import de.test.antennapod.EspressoTestUtils;
import org.junit.After;
import org.junit.Before;
diff --git a/app/src/androidTest/java/de/test/antennapod/ui/PreferencesTest.java b/app/src/androidTest/java/de/test/antennapod/ui/PreferencesTest.java
index 9ba4276be..8d956e3e4 100644
--- a/app/src/androidTest/java/de/test/antennapod/ui/PreferencesTest.java
+++ b/app/src/androidTest/java/de/test/antennapod/ui/PreferencesTest.java
@@ -9,7 +9,7 @@ import androidx.preference.PreferenceManager;
import androidx.test.filters.LargeTest;
import androidx.test.rule.ActivityTestRule;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.activity.PreferenceActivity;
+import de.danoeh.antennapod.ui.screen.preferences.PreferenceActivity;
import de.danoeh.antennapod.core.storage.APCleanupAlgorithm;
import de.danoeh.antennapod.core.storage.APNullCleanupAlgorithm;
import de.danoeh.antennapod.core.storage.APQueueCleanupAlgorithm;
diff --git a/app/src/androidTest/java/de/test/antennapod/ui/QueueFragmentTest.java b/app/src/androidTest/java/de/test/antennapod/ui/QueueFragmentTest.java
index da323af76..0f472b699 100644
--- a/app/src/androidTest/java/de/test/antennapod/ui/QueueFragmentTest.java
+++ b/app/src/androidTest/java/de/test/antennapod/ui/QueueFragmentTest.java
@@ -5,7 +5,7 @@ import androidx.test.espresso.intent.rule.IntentsTestRule;
import androidx.test.ext.junit.runners.AndroidJUnit4;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
-import de.danoeh.antennapod.fragment.QueueFragment;
+import de.danoeh.antennapod.ui.screen.queue.QueueFragment;
import de.test.antennapod.EspressoTestUtils;
import org.junit.Before;
import org.junit.Rule;
diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml
index 66f0b8766..3d608133f 100644
--- a/app/src/main/AndroidManifest.xml
+++ b/app/src/main/AndroidManifest.xml
@@ -44,7 +44,7 @@
android:networkSecurityConfig="@xml/network_security_config">
<activity
- android:name=".activity.PlaybackSpeedDialogActivity"
+ android:name=".ui.screen.playback.PlaybackSpeedDialogActivity"
android:noHistory="true"
android:exported="false"
android:excludeFromRecents="true"
@@ -129,7 +129,7 @@
</activity>
<activity
- android:name=".activity.PreferenceActivity"
+ android:name=".ui.screen.preferences.PreferenceActivity"
android:configChanges="keyboardHidden|orientation|screenSize"
android:exported="false"
android:label="@string/settings_label">
@@ -167,15 +167,15 @@
</intent-filter>
</activity>
<activity
- android:name=".activity.BugReportActivity"
+ android:name=".ui.screen.preferences.BugReportActivity"
android:label="@string/bug_report_title">
<meta-data
android:name="android.support.PARENT_ACTIVITY"
- android:value="de.danoeh.antennapod.activity.PreferenceActivity"/>
+ android:value="de.danoeh.antennapod.ui.screen.preferences.PreferenceActivity"/>
</activity>
<activity
- android:name=".activity.VideoplayerActivity"
+ android:name=".ui.screen.playback.video.VideoplayerActivity"
android:configChanges="keyboardHidden|orientation|screenSize|screenLayout|smallestScreenSize"
android:supportsPictureInPicture="true"
android:screenOrientation="sensorLandscape"
@@ -190,7 +190,7 @@
</activity>
<activity
- android:name=".activity.OnlineFeedViewActivity"
+ android:name=".ui.screen.onlinefeedview.OnlineFeedViewActivity"
android:configChanges="orientation|screenSize"
android:theme="@style/Theme.AntennaPod.Dark.Translucent"
android:label="@string/add_feed_label"
@@ -322,24 +322,7 @@
</activity>
<receiver
- android:name=".receiver.ConnectivityActionReceiver"
- android:exported="true">
- <intent-filter>
- <action android:name="android.net.conn.CONNECTIVITY_CHANGE"/>
- </intent-filter>
- </receiver>
-
- <receiver
- android:name=".receiver.PowerConnectionReceiver"
- android:exported="true">
- <intent-filter>
- <action android:name="android.intent.action.ACTION_POWER_CONNECTED"/>
- <action android:name="android.intent.action.ACTION_POWER_DISCONNECTED"/>
- </intent-filter>
- </receiver>
-
- <receiver
- android:name=".receiver.SPAReceiver"
+ android:name=".spa.SPAReceiver"
android:exported="true">
<intent-filter>
<action android:name="de.danoeh.antennapdsp.intent.SP_APPS_QUERY_FEEDS_RESPONSE"/>
diff --git a/app/src/main/java/de/danoeh/antennapod/ClientConfigurator.java b/app/src/main/java/de/danoeh/antennapod/ClientConfigurator.java
index a0cf4bfc9..43be25afa 100644
--- a/app/src/main/java/de/danoeh/antennapod/ClientConfigurator.java
+++ b/app/src/main/java/de/danoeh/antennapod/ClientConfigurator.java
@@ -20,7 +20,6 @@ import de.danoeh.antennapod.net.common.AntennapodHttpClient;
import de.danoeh.antennapod.net.download.serviceinterface.DownloadServiceInterface;
import de.danoeh.antennapod.net.download.service.feed.DownloadServiceInterfaceImpl;
import de.danoeh.antennapod.net.common.NetworkUtils;
-import de.danoeh.antennapod.core.util.download.NetworkConnectionChangeHandler;
import de.danoeh.antennapod.net.ssl.SslProviderInstaller;
import de.danoeh.antennapod.storage.database.PodDBAdapter;
@@ -48,7 +47,6 @@ public class ClientConfigurator {
PlaybackPreferences.init(context);
SslProviderInstaller.install(context);
NetworkUtils.init(context);
- NetworkConnectionChangeHandler.init(context);
DownloadServiceInterface.setImpl(new DownloadServiceInterfaceImpl());
FeedUpdateManager.setInstance(new FeedUpdateManagerImpl());
AutoDownloadManager.setInstance(new AutoDownloadManagerImpl());
diff --git a/app/src/main/java/de/danoeh/antennapod/error/CrashReportWriter.java b/app/src/main/java/de/danoeh/antennapod/CrashReportWriter.java
index 356fd34ee..92d6785ab 100644
--- a/app/src/main/java/de/danoeh/antennapod/error/CrashReportWriter.java
+++ b/app/src/main/java/de/danoeh/antennapod/CrashReportWriter.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.error;
+package de.danoeh.antennapod;
import android.os.Build;
import android.util.Log;
diff --git a/app/src/main/java/de/danoeh/antennapod/PodcastApp.java b/app/src/main/java/de/danoeh/antennapod/PodcastApp.java
index a83e97d26..fb8c21883 100644
--- a/app/src/main/java/de/danoeh/antennapod/PodcastApp.java
+++ b/app/src/main/java/de/danoeh/antennapod/PodcastApp.java
@@ -5,11 +5,9 @@ import android.os.StrictMode;
import com.google.android.material.color.DynamicColors;
-import de.danoeh.antennapod.error.CrashReportWriter;
-import de.danoeh.antennapod.error.RxJavaErrorHandlerSetup;
-import de.danoeh.antennapod.preferences.PreferenceUpgrader;
import de.danoeh.antennapod.spa.SPAUtil;
import org.greenrobot.eventbus.EventBus;
+import org.greenrobot.eventbus.EventBusException;
/** Main application class. */
public class PodcastApp extends Application {
@@ -30,16 +28,20 @@ public class PodcastApp extends Application {
StrictMode.setVmPolicy(builder.build());
}
+ try {
+ // Robolectric calls onCreate for every test, which causes problems with static members
+ EventBus.builder()
+ .addIndex(new ApEventBusIndex())
+ .logNoSubscriberMessages(false)
+ .sendNoSubscriberEvent(false)
+ .installDefaultEventBus();
+ } catch (EventBusException e) {
+ e.printStackTrace();
+ }
+
+ DynamicColors.applyToActivitiesIfAvailable(this);
ClientConfigurator.initialize(this);
PreferenceUpgrader.checkUpgrades(this);
-
SPAUtil.sendSPAppsQueryFeedsIntent(this);
- EventBus.builder()
- .addIndex(new ApEventBusIndex())
- .logNoSubscriberMessages(false)
- .sendNoSubscriberEvent(false)
- .installDefaultEventBus();
-
- DynamicColors.applyToActivitiesIfAvailable(this);
}
}
diff --git a/app/src/main/java/de/danoeh/antennapod/preferences/PreferenceUpgrader.java b/app/src/main/java/de/danoeh/antennapod/PreferenceUpgrader.java
index 03355510d..02abc23fb 100644
--- a/app/src/main/java/de/danoeh/antennapod/preferences/PreferenceUpgrader.java
+++ b/app/src/main/java/de/danoeh/antennapod/PreferenceUpgrader.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.preferences;
+package de.danoeh.antennapod;
import android.content.Context;
import android.content.SharedPreferences;
@@ -13,13 +13,13 @@ import java.util.concurrent.TimeUnit;
import de.danoeh.antennapod.BuildConfig;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.storage.preferences.SleepTimerPreferences;
-import de.danoeh.antennapod.error.CrashReportWriter;
-import de.danoeh.antennapod.fragment.AllEpisodesFragment;
+import de.danoeh.antennapod.CrashReportWriter;
+import de.danoeh.antennapod.ui.screen.AllEpisodesFragment;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
import de.danoeh.antennapod.storage.preferences.UserPreferences.EnqueueLocation;
-import de.danoeh.antennapod.fragment.QueueFragment;
-import de.danoeh.antennapod.fragment.swipeactions.SwipeAction;
-import de.danoeh.antennapod.fragment.swipeactions.SwipeActions;
+import de.danoeh.antennapod.ui.screen.queue.QueueFragment;
+import de.danoeh.antennapod.ui.swipeactions.SwipeAction;
+import de.danoeh.antennapod.ui.swipeactions.SwipeActions;
public class PreferenceUpgrader {
private static final String PREF_CONFIGURED_VERSION = "version_code";
diff --git a/app/src/main/java/de/danoeh/antennapod/error/RxJavaErrorHandlerSetup.java b/app/src/main/java/de/danoeh/antennapod/RxJavaErrorHandlerSetup.java
index 1c7f5f0b4..e909702ce 100644
--- a/app/src/main/java/de/danoeh/antennapod/error/RxJavaErrorHandlerSetup.java
+++ b/app/src/main/java/de/danoeh/antennapod/RxJavaErrorHandlerSetup.java
@@ -1,7 +1,6 @@
-package de.danoeh.antennapod.error;
+package de.danoeh.antennapod;
import android.util.Log;
-import de.danoeh.antennapod.BuildConfig;
import io.reactivex.exceptions.UndeliverableException;
import io.reactivex.plugins.RxJavaPlugins;
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/CancelDownloadActionButton.java b/app/src/main/java/de/danoeh/antennapod/actionbutton/CancelDownloadActionButton.java
index fa4b19b4d..3e8e65200 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/CancelDownloadActionButton.java
+++ b/app/src/main/java/de/danoeh/antennapod/actionbutton/CancelDownloadActionButton.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.adapter.actionbutton;
+package de.danoeh.antennapod.actionbutton;
import android.content.Context;
import androidx.annotation.DrawableRes;
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/DeleteActionButton.java b/app/src/main/java/de/danoeh/antennapod/actionbutton/DeleteActionButton.java
index 6b9114e81..3e88270da 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/DeleteActionButton.java
+++ b/app/src/main/java/de/danoeh/antennapod/actionbutton/DeleteActionButton.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.adapter.actionbutton;
+package de.danoeh.antennapod.actionbutton;
import android.content.Context;
import android.view.View;
@@ -11,7 +11,7 @@ import de.danoeh.antennapod.R;
import de.danoeh.antennapod.model.feed.FeedItem;
import de.danoeh.antennapod.model.feed.FeedMedia;
import de.danoeh.antennapod.storage.database.DBWriter;
-import de.danoeh.antennapod.view.LocalDeleteModal;
+import de.danoeh.antennapod.ui.view.LocalDeleteModal;
public class DeleteActionButton extends ItemActionButton {
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/DownloadActionButton.java b/app/src/main/java/de/danoeh/antennapod/actionbutton/DownloadActionButton.java
index af573218c..15f07d207 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/DownloadActionButton.java
+++ b/app/src/main/java/de/danoeh/antennapod/actionbutton/DownloadActionButton.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.adapter.actionbutton;
+package de.danoeh.antennapod.actionbutton;
import android.content.Context;
import android.view.View;
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/ItemActionButton.java b/app/src/main/java/de/danoeh/antennapod/actionbutton/ItemActionButton.java
index 07ed5d443..84b246167 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/ItemActionButton.java
+++ b/app/src/main/java/de/danoeh/antennapod/actionbutton/ItemActionButton.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.adapter.actionbutton;
+package de.danoeh.antennapod.actionbutton;
import android.content.Context;
import android.widget.ImageView;
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/MarkAsPlayedActionButton.java b/app/src/main/java/de/danoeh/antennapod/actionbutton/MarkAsPlayedActionButton.java
index 34fef11dc..673a0c6ff 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/MarkAsPlayedActionButton.java
+++ b/app/src/main/java/de/danoeh/antennapod/actionbutton/MarkAsPlayedActionButton.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.adapter.actionbutton;
+package de.danoeh.antennapod.actionbutton;
import android.content.Context;
import androidx.annotation.DrawableRes;
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/PauseActionButton.java b/app/src/main/java/de/danoeh/antennapod/actionbutton/PauseActionButton.java
index 44b488df9..effb33e78 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/PauseActionButton.java
+++ b/app/src/main/java/de/danoeh/antennapod/actionbutton/PauseActionButton.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.adapter.actionbutton;
+package de.danoeh.antennapod.actionbutton;
import android.content.Context;
import android.view.KeyEvent;
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/PlayActionButton.java b/app/src/main/java/de/danoeh/antennapod/actionbutton/PlayActionButton.java
index 45a8e0cdd..6eeb42065 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/PlayActionButton.java
+++ b/app/src/main/java/de/danoeh/antennapod/actionbutton/PlayActionButton.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.adapter.actionbutton;
+package de.danoeh.antennapod.actionbutton;
import android.content.Context;
import android.util.Log;
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/PlayLocalActionButton.java b/app/src/main/java/de/danoeh/antennapod/actionbutton/PlayLocalActionButton.java
index 6acb62434..62a965494 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/PlayLocalActionButton.java
+++ b/app/src/main/java/de/danoeh/antennapod/actionbutton/PlayLocalActionButton.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.adapter.actionbutton;
+package de.danoeh.antennapod.actionbutton;
import android.content.Context;
import androidx.annotation.DrawableRes;
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/StreamActionButton.java b/app/src/main/java/de/danoeh/antennapod/actionbutton/StreamActionButton.java
index 372a7984e..afe1fcce8 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/StreamActionButton.java
+++ b/app/src/main/java/de/danoeh/antennapod/actionbutton/StreamActionButton.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.adapter.actionbutton;
+package de.danoeh.antennapod.actionbutton;
import android.content.Context;
@@ -13,7 +13,7 @@ import de.danoeh.antennapod.playback.service.PlaybackService;
import de.danoeh.antennapod.playback.service.PlaybackServiceStarter;
import de.danoeh.antennapod.storage.preferences.UsageStatistics;
import de.danoeh.antennapod.net.common.NetworkUtils;
-import de.danoeh.antennapod.dialog.StreamingConfirmationDialog;
+import de.danoeh.antennapod.ui.StreamingConfirmationDialog;
public class StreamActionButton extends ItemActionButton {
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/VisitWebsiteActionButton.java b/app/src/main/java/de/danoeh/antennapod/actionbutton/VisitWebsiteActionButton.java
index 03ccce2fe..dbe937c14 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/actionbutton/VisitWebsiteActionButton.java
+++ b/app/src/main/java/de/danoeh/antennapod/actionbutton/VisitWebsiteActionButton.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.adapter.actionbutton;
+package de.danoeh.antennapod.actionbutton;
import android.content.Context;
import android.view.View;
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 32884c9c9..fd4007736 100644
--- a/app/src/main/java/de/danoeh/antennapod/activity/MainActivity.java
+++ b/app/src/main/java/de/danoeh/antennapod/activity/MainActivity.java
@@ -40,23 +40,23 @@ import de.danoeh.antennapod.net.download.serviceinterface.FeedUpdateManager;
import de.danoeh.antennapod.net.sync.serviceinterface.SynchronizationQueueSink;
import de.danoeh.antennapod.ui.appstartintent.MediaButtonStarter;
import de.danoeh.antennapod.ui.common.ThemeSwitcher;
-import de.danoeh.antennapod.dialog.rating.RatingDialogManager;
+import de.danoeh.antennapod.ui.screen.rating.RatingDialogManager;
import de.danoeh.antennapod.event.EpisodeDownloadEvent;
import de.danoeh.antennapod.event.FeedUpdateRunningEvent;
import de.danoeh.antennapod.event.MessageEvent;
-import de.danoeh.antennapod.fragment.AddFeedFragment;
-import de.danoeh.antennapod.fragment.AllEpisodesFragment;
-import de.danoeh.antennapod.fragment.AudioPlayerFragment;
-import de.danoeh.antennapod.fragment.CompletedDownloadsFragment;
-import de.danoeh.antennapod.fragment.DownloadLogFragment;
-import de.danoeh.antennapod.fragment.FeedItemlistFragment;
-import de.danoeh.antennapod.fragment.InboxFragment;
-import de.danoeh.antennapod.fragment.NavDrawerFragment;
-import de.danoeh.antennapod.fragment.PlaybackHistoryFragment;
-import de.danoeh.antennapod.fragment.QueueFragment;
-import de.danoeh.antennapod.fragment.SearchFragment;
-import de.danoeh.antennapod.fragment.SubscriptionFragment;
-import de.danoeh.antennapod.fragment.TransitionEffect;
+import de.danoeh.antennapod.ui.screen.AddFeedFragment;
+import de.danoeh.antennapod.ui.screen.AllEpisodesFragment;
+import de.danoeh.antennapod.ui.screen.playback.audio.AudioPlayerFragment;
+import de.danoeh.antennapod.ui.screen.download.CompletedDownloadsFragment;
+import de.danoeh.antennapod.ui.screen.download.DownloadLogFragment;
+import de.danoeh.antennapod.ui.screen.feed.FeedItemlistFragment;
+import de.danoeh.antennapod.ui.screen.InboxFragment;
+import de.danoeh.antennapod.ui.screen.drawer.NavDrawerFragment;
+import de.danoeh.antennapod.ui.screen.PlaybackHistoryFragment;
+import de.danoeh.antennapod.ui.screen.queue.QueueFragment;
+import de.danoeh.antennapod.ui.screen.SearchFragment;
+import de.danoeh.antennapod.ui.screen.subscriptions.SubscriptionFragment;
+import de.danoeh.antennapod.ui.TransitionEffect;
import de.danoeh.antennapod.model.download.DownloadStatus;
import de.danoeh.antennapod.net.download.serviceinterface.DownloadServiceInterface;
import de.danoeh.antennapod.playback.cast.CastEnabledActivity;
@@ -65,8 +65,8 @@ import de.danoeh.antennapod.storage.preferences.UserPreferences;
import de.danoeh.antennapod.ui.appstartintent.MainActivityStarter;
import de.danoeh.antennapod.ui.common.ThemeUtils;
import de.danoeh.antennapod.ui.discovery.DiscoveryFragment;
-import de.danoeh.antennapod.ui.home.HomeFragment;
-import de.danoeh.antennapod.view.LockableBottomSheetBehavior;
+import de.danoeh.antennapod.ui.screen.home.HomeFragment;
+import de.danoeh.antennapod.ui.view.LockableBottomSheetBehavior;
import org.apache.commons.lang3.ArrayUtils;
import org.apache.commons.lang3.Validate;
import org.greenrobot.eventbus.EventBus;
diff --git a/app/src/main/java/de/danoeh/antennapod/activity/SplashActivity.java b/app/src/main/java/de/danoeh/antennapod/activity/SplashActivity.java
index 43da309d7..4ea33ca3e 100644
--- a/app/src/main/java/de/danoeh/antennapod/activity/SplashActivity.java
+++ b/app/src/main/java/de/danoeh/antennapod/activity/SplashActivity.java
@@ -7,7 +7,7 @@ import android.os.Bundle;
import android.view.View;
import android.widget.Toast;
import androidx.annotation.Nullable;
-import de.danoeh.antennapod.error.CrashReportWriter;
+import de.danoeh.antennapod.CrashReportWriter;
import de.danoeh.antennapod.storage.database.PodDBAdapter;
import io.reactivex.Completable;
import io.reactivex.android.schedulers.AndroidSchedulers;
diff --git a/app/src/main/java/de/danoeh/antennapod/receiver/ConnectivityActionReceiver.java b/app/src/main/java/de/danoeh/antennapod/receiver/ConnectivityActionReceiver.java
deleted file mode 100644
index 100869120..000000000
--- a/app/src/main/java/de/danoeh/antennapod/receiver/ConnectivityActionReceiver.java
+++ /dev/null
@@ -1,25 +0,0 @@
-package de.danoeh.antennapod.receiver;
-
-import android.content.BroadcastReceiver;
-import android.content.Context;
-import android.content.Intent;
-import android.net.ConnectivityManager;
-import android.text.TextUtils;
-import android.util.Log;
-
-import de.danoeh.antennapod.ClientConfigurator;
-import de.danoeh.antennapod.core.util.download.NetworkConnectionChangeHandler;
-
-public class ConnectivityActionReceiver extends BroadcastReceiver {
- private static final String TAG = "ConnectivityActionRecvr";
-
- @Override
- public void onReceive(final Context context, Intent intent) {
- if (TextUtils.equals(intent.getAction(), ConnectivityManager.CONNECTIVITY_ACTION)) {
- Log.d(TAG, "Received intent");
-
- ClientConfigurator.initialize(context);
- NetworkConnectionChangeHandler.networkChangedDetected();
- }
- }
-}
diff --git a/app/src/main/java/de/danoeh/antennapod/receiver/SPAReceiver.java b/app/src/main/java/de/danoeh/antennapod/spa/SPAReceiver.java
index 1628229be..e91192164 100644
--- a/app/src/main/java/de/danoeh/antennapod/receiver/SPAReceiver.java
+++ b/app/src/main/java/de/danoeh/antennapod/spa/SPAReceiver.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.receiver;
+package de.danoeh.antennapod.spa;
import android.content.BroadcastReceiver;
import android.content.Context;
diff --git a/app/src/main/java/de/danoeh/antennapod/spa/SPAUtil.java b/app/src/main/java/de/danoeh/antennapod/spa/SPAUtil.java
index f9c10041e..7630d49cd 100644
--- a/app/src/main/java/de/danoeh/antennapod/spa/SPAUtil.java
+++ b/app/src/main/java/de/danoeh/antennapod/spa/SPAUtil.java
@@ -7,7 +7,6 @@ import androidx.preference.PreferenceManager;
import android.util.Log;
import de.danoeh.antennapod.BuildConfig;
-import de.danoeh.antennapod.receiver.SPAReceiver;
/**
* Provides methods related to AntennaPodSP (https://github.com/danieloeh/AntennaPodSP)
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/AllEpisodesFilterDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/AllEpisodesFilterDialog.java
index f47a8f8eb..d3464cd54 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/AllEpisodesFilterDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/AllEpisodesFilterDialog.java
@@ -1,7 +1,8 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui;
import android.os.Bundle;
import de.danoeh.antennapod.model.feed.FeedItemFilter;
+import de.danoeh.antennapod.ui.screen.feed.ItemFilterDialog;
import org.greenrobot.eventbus.EventBus;
import java.util.Set;
@@ -17,7 +18,7 @@ public class AllEpisodesFilterDialog extends ItemFilterDialog {
}
@Override
- void onFilterChanged(Set<String> newFilterValues) {
+ public void onFilterChanged(Set<String> newFilterValues) {
EventBus.getDefault().post(new AllEpisodesFilterChangedEvent(newFilterValues));
}
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/CoverLoader.java b/app/src/main/java/de/danoeh/antennapod/ui/CoverLoader.java
index c87228cdd..370a15919 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/CoverLoader.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/CoverLoader.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.adapter;
+package de.danoeh.antennapod.ui;
import android.graphics.drawable.Drawable;
import android.view.View;
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/FeedItemFilterDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/FeedItemFilterDialog.java
index a88a6600a..cce78013a 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/FeedItemFilterDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/FeedItemFilterDialog.java
@@ -1,8 +1,9 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui;
import android.os.Bundle;
import de.danoeh.antennapod.storage.database.DBWriter;
import de.danoeh.antennapod.model.feed.Feed;
+import de.danoeh.antennapod.ui.screen.feed.ItemFilterDialog;
import java.util.Set;
@@ -19,7 +20,7 @@ public class FeedItemFilterDialog extends ItemFilterDialog {
}
@Override
- void onFilterChanged(Set<String> newFilterValues) {
+ public void onFilterChanged(Set<String> newFilterValues) {
long feedId = getArguments().getLong(ARGUMENT_FEED_ID);
DBWriter.setFeedItemsFilter(feedId, newFilterValues);
}
diff --git a/core/src/main/java/de/danoeh/antennapod/core/menuhandler/MenuItemUtils.java b/app/src/main/java/de/danoeh/antennapod/ui/MenuItemUtils.java
index 829add126..f9e8f0568 100644
--- a/core/src/main/java/de/danoeh/antennapod/core/menuhandler/MenuItemUtils.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/MenuItemUtils.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.core.menuhandler;
+package de.danoeh.antennapod.ui;
import android.view.Menu;
import android.view.MenuItem;
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/SelectableAdapter.java b/app/src/main/java/de/danoeh/antennapod/ui/SelectableAdapter.java
index 70d00cbff..918562ec3 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/SelectableAdapter.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/SelectableAdapter.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.adapter;
+package de.danoeh.antennapod.ui;
import android.app.Activity;
import android.view.ActionMode;
@@ -21,7 +21,7 @@ public abstract class SelectableAdapter<T extends RecyclerView.ViewHolder> exten
private final HashSet<Long> selectedIds = new HashSet<>();
private final Activity activity;
private OnSelectModeListener onSelectModeListener;
- boolean shouldSelectLazyLoadedItems = false;
+ protected boolean shouldSelectLazyLoadedItems = false;
private int totalNumberOfItems = COUNT_AUTOMATICALLY;
public SelectableAdapter(Activity activity) {
@@ -153,7 +153,7 @@ public abstract class SelectableAdapter<T extends RecyclerView.ViewHolder> exten
}
}
- void updateTitle() {
+ protected void updateTitle() {
if (actionMode == null) {
return;
}
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/SimpleChipAdapter.java b/app/src/main/java/de/danoeh/antennapod/ui/SimpleChipAdapter.java
index c7a04c3c7..904d01883 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/SimpleChipAdapter.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/SimpleChipAdapter.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.adapter;
+package de.danoeh.antennapod.ui;
import android.content.Context;
import android.view.ViewGroup;
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/StreamingConfirmationDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/StreamingConfirmationDialog.java
index 5b733138f..6199aa0fd 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/StreamingConfirmationDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/StreamingConfirmationDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui;
import android.content.Context;
import com.google.android.material.dialog.MaterialAlertDialogBuilder;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/TransitionEffect.java b/app/src/main/java/de/danoeh/antennapod/ui/TransitionEffect.java
index e3ec14890..092aeb3a5 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/TransitionEffect.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/TransitionEffect.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment;
+package de.danoeh.antennapod.ui;
public enum TransitionEffect {
NONE, FADE, SLIDE
diff --git a/core/src/main/java/de/danoeh/antennapod/core/util/syndication/HtmlToPlainText.java b/app/src/main/java/de/danoeh/antennapod/ui/cleaner/HtmlToPlainText.java
index c5f0727c2..29099c1fd 100644
--- a/core/src/main/java/de/danoeh/antennapod/core/util/syndication/HtmlToPlainText.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/cleaner/HtmlToPlainText.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.core.util.syndication;
+package de.danoeh.antennapod.ui.cleaner;
import android.text.TextUtils;
diff --git a/core/src/main/java/de/danoeh/antennapod/core/util/gui/ShownotesCleaner.java b/app/src/main/java/de/danoeh/antennapod/ui/cleaner/ShownotesCleaner.java
index 7bf9257a1..57f91e35c 100644
--- a/core/src/main/java/de/danoeh/antennapod/core/util/gui/ShownotesCleaner.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/cleaner/ShownotesCleaner.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.core.util.gui;
+package de.danoeh.antennapod.ui.cleaner;
import android.content.Context;
import android.content.res.TypedArray;
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/EpisodeItemListAdapter.java b/app/src/main/java/de/danoeh/antennapod/ui/episodeslist/EpisodeItemListAdapter.java
index 0ec7018a7..cb026240a 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/EpisodeItemListAdapter.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/episodeslist/EpisodeItemListAdapter.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.adapter;
+package de.danoeh.antennapod.ui.episodeslist;
import android.app.Activity;
import android.os.Build;
@@ -14,6 +14,7 @@ import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.recyclerview.widget.RecyclerView;
+import de.danoeh.antennapod.ui.SelectableAdapter;
import de.danoeh.antennapod.ui.common.ThemeUtils;
import org.apache.commons.lang3.ArrayUtils;
@@ -25,9 +26,7 @@ import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
import de.danoeh.antennapod.model.feed.FeedItem;
import de.danoeh.antennapod.core.util.FeedItemUtil;
-import de.danoeh.antennapod.fragment.ItemPagerFragment;
-import de.danoeh.antennapod.menuhandler.FeedItemMenuHandler;
-import de.danoeh.antennapod.view.viewholder.EpisodeItemViewHolder;
+import de.danoeh.antennapod.ui.screen.episode.ItemPagerFragment;
/**
* List adapter for the list of new episodes.
diff --git a/app/src/main/java/de/danoeh/antennapod/view/EpisodeItemListRecyclerView.java b/app/src/main/java/de/danoeh/antennapod/ui/episodeslist/EpisodeItemListRecyclerView.java
index fb1c533c5..a4f33ec98 100644
--- a/app/src/main/java/de/danoeh/antennapod/view/EpisodeItemListRecyclerView.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/episodeslist/EpisodeItemListRecyclerView.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.view;
+package de.danoeh.antennapod.ui.episodeslist;
import android.content.Context;
import android.content.SharedPreferences;
diff --git a/app/src/main/java/de/danoeh/antennapod/view/viewholder/EpisodeItemViewHolder.java b/app/src/main/java/de/danoeh/antennapod/ui/episodeslist/EpisodeItemViewHolder.java
index fd547aa09..2d9cf7004 100644
--- a/app/src/main/java/de/danoeh/antennapod/view/viewholder/EpisodeItemViewHolder.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/episodeslist/EpisodeItemViewHolder.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.view.viewholder;
+package de.danoeh.antennapod.ui.episodeslist;
import android.os.Build;
import android.text.Layout;
@@ -18,10 +18,9 @@ import com.google.android.material.elevation.SurfaceColors;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
-import de.danoeh.antennapod.adapter.CoverLoader;
-import de.danoeh.antennapod.adapter.actionbutton.ItemActionButton;
+import de.danoeh.antennapod.ui.CoverLoader;
+import de.danoeh.antennapod.actionbutton.ItemActionButton;
import de.danoeh.antennapod.playback.service.PlaybackStatus;
-import de.danoeh.antennapod.core.util.download.MediaSizeLoader;
import de.danoeh.antennapod.event.playback.PlaybackPositionEvent;
import de.danoeh.antennapod.ui.common.DateFormatter;
import de.danoeh.antennapod.model.feed.FeedItem;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/actions/EpisodeMultiSelectActionHandler.java b/app/src/main/java/de/danoeh/antennapod/ui/episodeslist/EpisodeMultiSelectActionHandler.java
index 9325037ad..2a9f76939 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/actions/EpisodeMultiSelectActionHandler.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/episodeslist/EpisodeMultiSelectActionHandler.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment.actions;
+package de.danoeh.antennapod.ui.episodeslist;
import android.util.Log;
@@ -14,7 +14,7 @@ import de.danoeh.antennapod.net.download.serviceinterface.DownloadServiceInterfa
import de.danoeh.antennapod.storage.database.DBWriter;
import de.danoeh.antennapod.storage.database.LongList;
import de.danoeh.antennapod.model.feed.FeedItem;
-import de.danoeh.antennapod.view.LocalDeleteModal;
+import de.danoeh.antennapod.ui.view.LocalDeleteModal;
public class EpisodeMultiSelectActionHandler {
private static final String TAG = "EpisodeSelectHandler";
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/EpisodesListFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/episodeslist/EpisodesListFragment.java
index 0f9e21b6e..054183f7c 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/EpisodesListFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/episodeslist/EpisodesListFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment;
+package de.danoeh.antennapod.ui.episodeslist;
import android.content.DialogInterface;
import android.os.Bundle;
@@ -24,6 +24,7 @@ import com.google.android.material.appbar.MaterialToolbar;
import com.google.android.material.snackbar.Snackbar;
import com.leinardi.android.speeddial.SpeedDialView;
+import de.danoeh.antennapod.ui.screen.SearchFragment;
import de.danoeh.antennapod.net.download.serviceinterface.FeedUpdateManager;
import org.greenrobot.eventbus.EventBus;
import org.greenrobot.eventbus.Subscribe;
@@ -35,9 +36,8 @@ import java.util.List;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
-import de.danoeh.antennapod.adapter.EpisodeItemListAdapter;
-import de.danoeh.antennapod.core.dialog.ConfirmationDialog;
-import de.danoeh.antennapod.core.menuhandler.MenuItemUtils;
+import de.danoeh.antennapod.core.util.ConfirmationDialog;
+import de.danoeh.antennapod.ui.MenuItemUtils;
import de.danoeh.antennapod.core.util.FeedItemUtil;
import de.danoeh.antennapod.event.EpisodeDownloadEvent;
import de.danoeh.antennapod.event.FeedItemEvent;
@@ -46,15 +46,11 @@ import de.danoeh.antennapod.event.FeedUpdateRunningEvent;
import de.danoeh.antennapod.event.PlayerStatusEvent;
import de.danoeh.antennapod.event.UnreadItemsUpdateEvent;
import de.danoeh.antennapod.event.playback.PlaybackPositionEvent;
-import de.danoeh.antennapod.fragment.actions.EpisodeMultiSelectActionHandler;
-import de.danoeh.antennapod.fragment.swipeactions.SwipeActions;
-import de.danoeh.antennapod.menuhandler.FeedItemMenuHandler;
+import de.danoeh.antennapod.ui.swipeactions.SwipeActions;
import de.danoeh.antennapod.model.feed.FeedItem;
import de.danoeh.antennapod.model.feed.FeedItemFilter;
-import de.danoeh.antennapod.view.EmptyViewHandler;
-import de.danoeh.antennapod.view.EpisodeItemListRecyclerView;
-import de.danoeh.antennapod.view.LiftOnScrollListener;
-import de.danoeh.antennapod.view.viewholder.EpisodeItemViewHolder;
+import de.danoeh.antennapod.ui.view.EmptyViewHandler;
+import de.danoeh.antennapod.ui.view.LiftOnScrollListener;
import io.reactivex.Completable;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
@@ -74,18 +70,16 @@ public abstract class EpisodesListFragment extends Fragment
protected boolean hasMoreItems = false;
private boolean displayUpArrow;
- EpisodeItemListRecyclerView recyclerView;
- EpisodeItemListAdapter listAdapter;
- EmptyViewHandler emptyView;
- SpeedDialView speedDialView;
- MaterialToolbar toolbar;
- SwipeRefreshLayout swipeRefreshLayout;
- SwipeActions swipeActions;
+ protected EpisodeItemListRecyclerView recyclerView;
+ protected EpisodeItemListAdapter listAdapter;
+ protected EmptyViewHandler emptyView;
+ protected SpeedDialView speedDialView;
+ protected MaterialToolbar toolbar;
+ protected SwipeRefreshLayout swipeRefreshLayout;
+ protected SwipeActions swipeActions;
private ProgressBar progressBar;
-
@NonNull
- List<FeedItem> episodes = new ArrayList<>();
-
+ protected List<FeedItem> episodes = new ArrayList<>();
protected Disposable disposable;
protected TextView txtvInformation;
@@ -406,7 +400,7 @@ public abstract class EpisodesListFragment extends Fragment
loadItems();
}
- void loadItems() {
+ protected void loadItems() {
if (disposable != null) {
disposable.dispose();
}
diff --git a/app/src/main/java/de/danoeh/antennapod/menuhandler/FeedItemMenuHandler.java b/app/src/main/java/de/danoeh/antennapod/ui/episodeslist/FeedItemMenuHandler.java
index 422f65090..12b455d1f 100644
--- a/app/src/main/java/de/danoeh/antennapod/menuhandler/FeedItemMenuHandler.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/episodeslist/FeedItemMenuHandler.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.menuhandler;
+package de.danoeh.antennapod.ui.episodeslist;
import android.content.Context;
import android.os.Handler;
@@ -25,14 +25,14 @@ import de.danoeh.antennapod.storage.preferences.SynchronizationSettings;
import de.danoeh.antennapod.core.util.FeedItemUtil;
import de.danoeh.antennapod.core.util.IntentUtils;
import de.danoeh.antennapod.playback.service.PlaybackStatus;
-import de.danoeh.antennapod.core.util.ShareUtils;
-import de.danoeh.antennapod.dialog.ShareDialog;
+import de.danoeh.antennapod.ui.share.ShareUtils;
+import de.danoeh.antennapod.ui.share.ShareDialog;
import de.danoeh.antennapod.model.feed.FeedItem;
import de.danoeh.antennapod.model.feed.FeedMedia;
import de.danoeh.antennapod.net.sync.model.EpisodeAction;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
import de.danoeh.antennapod.ui.appstartintent.MediaButtonStarter;
-import de.danoeh.antennapod.view.LocalDeleteModal;
+import de.danoeh.antennapod.ui.view.LocalDeleteModal;
/**
* Handles interactions with the FeedItemMenu.
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/HorizontalItemListAdapter.java b/app/src/main/java/de/danoeh/antennapod/ui/episodeslist/HorizontalItemListAdapter.java
index 4e8a2b05e..f40851ec2 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/HorizontalItemListAdapter.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/episodeslist/HorizontalItemListAdapter.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.adapter;
+package de.danoeh.antennapod.ui.episodeslist;
import android.view.ContextMenu;
import android.view.MenuInflater;
@@ -10,10 +10,8 @@ import androidx.recyclerview.widget.RecyclerView;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
import de.danoeh.antennapod.core.util.FeedItemUtil;
-import de.danoeh.antennapod.fragment.ItemPagerFragment;
-import de.danoeh.antennapod.menuhandler.FeedItemMenuHandler;
+import de.danoeh.antennapod.ui.screen.episode.ItemPagerFragment;
import de.danoeh.antennapod.model.feed.FeedItem;
-import de.danoeh.antennapod.view.viewholder.HorizontalItemViewHolder;
import org.apache.commons.lang3.ArrayUtils;
import java.lang.ref.WeakReference;
diff --git a/app/src/main/java/de/danoeh/antennapod/view/viewholder/HorizontalItemViewHolder.java b/app/src/main/java/de/danoeh/antennapod/ui/episodeslist/HorizontalItemViewHolder.java
index ee642c041..c297725b0 100644
--- a/app/src/main/java/de/danoeh/antennapod/view/viewholder/HorizontalItemViewHolder.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/episodeslist/HorizontalItemViewHolder.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.view.viewholder;
+package de.danoeh.antennapod.ui.episodeslist;
import android.view.LayoutInflater;
import android.view.View;
@@ -11,8 +11,8 @@ import androidx.recyclerview.widget.RecyclerView;
import com.google.android.material.elevation.SurfaceColors;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
-import de.danoeh.antennapod.adapter.CoverLoader;
-import de.danoeh.antennapod.adapter.actionbutton.ItemActionButton;
+import de.danoeh.antennapod.ui.CoverLoader;
+import de.danoeh.antennapod.actionbutton.ItemActionButton;
import de.danoeh.antennapod.ui.common.DateFormatter;
import de.danoeh.antennapod.playback.service.PlaybackStatus;
import de.danoeh.antennapod.event.playback.PlaybackPositionEvent;
diff --git a/core/src/main/java/de/danoeh/antennapod/core/util/download/MediaSizeLoader.java b/app/src/main/java/de/danoeh/antennapod/ui/episodeslist/MediaSizeLoader.java
index 779f3b947..57b29f3b3 100644
--- a/core/src/main/java/de/danoeh/antennapod/core/util/download/MediaSizeLoader.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/episodeslist/MediaSizeLoader.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.core.util.download;
+package de.danoeh.antennapod.ui.episodeslist;
import android.text.TextUtils;
import de.danoeh.antennapod.net.common.AntennapodHttpClient;
diff --git a/core/src/main/java/de/danoeh/antennapod/core/util/gui/MoreContentListFooterUtil.java b/app/src/main/java/de/danoeh/antennapod/ui/episodeslist/MoreContentListFooterUtil.java
index 6e5c3e84b..fe9ce71f0 100644
--- a/core/src/main/java/de/danoeh/antennapod/core/util/gui/MoreContentListFooterUtil.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/episodeslist/MoreContentListFooterUtil.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.core.util.gui;
+package de.danoeh.antennapod.ui.episodeslist;
import android.view.View;
import android.widget.ImageView;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/AddFeedFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/AddFeedFragment.java
index 8fe5e1c18..0b95fd601 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/AddFeedFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/AddFeedFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment;
+package de.danoeh.antennapod.ui.screen;
import android.content.ActivityNotFoundException;
import android.content.ClipData;
@@ -38,6 +38,7 @@ import de.danoeh.antennapod.net.discovery.ItunesPodcastSearcher;
import de.danoeh.antennapod.net.discovery.PodcastIndexPodcastSearcher;
import de.danoeh.antennapod.ui.appstartintent.OnlineFeedviewActivityStarter;
import de.danoeh.antennapod.ui.discovery.OnlineSearchFragment;
+import de.danoeh.antennapod.ui.screen.feed.FeedItemlistFragment;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.schedulers.Schedulers;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/AllEpisodesFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/AllEpisodesFragment.java
index 5ef188534..36466c990 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/AllEpisodesFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/AllEpisodesFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment;
+package de.danoeh.antennapod.ui.screen;
import android.os.Bundle;
import android.view.LayoutInflater;
@@ -9,13 +9,14 @@ import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.storage.database.DBReader;
-import de.danoeh.antennapod.dialog.AllEpisodesFilterDialog;
-import de.danoeh.antennapod.dialog.ItemSortDialog;
+import de.danoeh.antennapod.ui.AllEpisodesFilterDialog;
+import de.danoeh.antennapod.ui.screen.feed.ItemSortDialog;
import de.danoeh.antennapod.event.FeedListUpdateEvent;
import de.danoeh.antennapod.model.feed.FeedItem;
import de.danoeh.antennapod.model.feed.FeedItemFilter;
import de.danoeh.antennapod.model.feed.SortOrder;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
+import de.danoeh.antennapod.ui.episodeslist.EpisodesListFragment;
import org.apache.commons.lang3.StringUtils;
import org.greenrobot.eventbus.EventBus;
import org.greenrobot.eventbus.Subscribe;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/InboxFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/InboxFragment.java
index e8016675b..5ac6e5bef 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/InboxFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/InboxFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment;
+package de.danoeh.antennapod.ui.screen;
import android.content.Context;
import android.content.SharedPreferences;
@@ -16,12 +16,13 @@ import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
import de.danoeh.antennapod.storage.database.DBReader;
import de.danoeh.antennapod.storage.database.DBWriter;
-import de.danoeh.antennapod.dialog.ItemSortDialog;
+import de.danoeh.antennapod.ui.screen.feed.ItemSortDialog;
import de.danoeh.antennapod.event.FeedListUpdateEvent;
import de.danoeh.antennapod.model.feed.FeedItem;
import de.danoeh.antennapod.model.feed.FeedItemFilter;
import de.danoeh.antennapod.model.feed.SortOrder;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
+import de.danoeh.antennapod.ui.episodeslist.EpisodesListFragment;
import org.greenrobot.eventbus.EventBus;
import java.util.List;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/PlaybackHistoryFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/PlaybackHistoryFragment.java
index beac47f7f..4efdf38a3 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/PlaybackHistoryFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/PlaybackHistoryFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment;
+package de.danoeh.antennapod.ui.screen;
import android.content.DialogInterface;
import android.os.Bundle;
@@ -8,13 +8,14 @@ import android.view.View;
import android.view.ViewGroup;
import androidx.annotation.NonNull;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.core.dialog.ConfirmationDialog;
+import de.danoeh.antennapod.core.util.ConfirmationDialog;
import de.danoeh.antennapod.storage.database.DBReader;
import de.danoeh.antennapod.storage.database.DBWriter;
import de.danoeh.antennapod.event.playback.PlaybackHistoryEvent;
import de.danoeh.antennapod.model.feed.FeedItem;
import de.danoeh.antennapod.model.feed.FeedItemFilter;
import de.danoeh.antennapod.model.feed.SortOrder;
+import de.danoeh.antennapod.ui.episodeslist.EpisodesListFragment;
import org.greenrobot.eventbus.Subscribe;
import org.greenrobot.eventbus.ThreadMode;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/SearchFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/SearchFragment.java
index 73fce9f1f..8e21117b3 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/SearchFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/SearchFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment;
+package de.danoeh.antennapod.ui.screen;
import android.content.Context;
@@ -28,28 +28,28 @@ import com.leinardi.android.speeddial.SpeedDialView;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
-import de.danoeh.antennapod.adapter.EpisodeItemListAdapter;
-import de.danoeh.antennapod.adapter.HorizontalFeedListAdapter;
-import de.danoeh.antennapod.core.menuhandler.MenuItemUtils;
+import de.danoeh.antennapod.ui.episodeslist.EpisodeItemListAdapter;
+import de.danoeh.antennapod.ui.screen.subscriptions.HorizontalFeedListAdapter;
+import de.danoeh.antennapod.ui.MenuItemUtils;
import de.danoeh.antennapod.databinding.MultiSelectSpeedDialBinding;
import de.danoeh.antennapod.event.EpisodeDownloadEvent;
import de.danoeh.antennapod.event.FeedItemEvent;
import de.danoeh.antennapod.event.playback.PlaybackPositionEvent;
import de.danoeh.antennapod.event.PlayerStatusEvent;
import de.danoeh.antennapod.event.UnreadItemsUpdateEvent;
-import de.danoeh.antennapod.fragment.actions.EpisodeMultiSelectActionHandler;
+import de.danoeh.antennapod.ui.episodeslist.EpisodeMultiSelectActionHandler;
import de.danoeh.antennapod.model.feed.Feed;
import de.danoeh.antennapod.model.feed.FeedItem;
import de.danoeh.antennapod.core.util.FeedItemUtil;
-import de.danoeh.antennapod.menuhandler.FeedItemMenuHandler;
+import de.danoeh.antennapod.ui.episodeslist.FeedItemMenuHandler;
import de.danoeh.antennapod.net.discovery.CombinedSearcher;
import de.danoeh.antennapod.storage.database.DBReader;
import de.danoeh.antennapod.ui.appstartintent.OnlineFeedviewActivityStarter;
import de.danoeh.antennapod.ui.discovery.OnlineSearchFragment;
-import de.danoeh.antennapod.view.EmptyViewHandler;
-import de.danoeh.antennapod.view.EpisodeItemListRecyclerView;
-import de.danoeh.antennapod.view.LiftOnScrollListener;
-import de.danoeh.antennapod.view.viewholder.EpisodeItemViewHolder;
+import de.danoeh.antennapod.ui.view.EmptyViewHandler;
+import de.danoeh.antennapod.ui.episodeslist.EpisodeItemListRecyclerView;
+import de.danoeh.antennapod.ui.view.LiftOnScrollListener;
+import de.danoeh.antennapod.ui.episodeslist.EpisodeItemViewHolder;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.disposables.Disposable;
@@ -60,7 +60,7 @@ import org.greenrobot.eventbus.ThreadMode;
import java.util.Collections;
import java.util.List;
-import de.danoeh.antennapod.menuhandler.FeedMenuHandler;
+import de.danoeh.antennapod.ui.screen.subscriptions.FeedMenuHandler;
import de.danoeh.antennapod.event.FeedListUpdateEvent;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/ChaptersFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/chapter/ChaptersFragment.java
index 14a8e68e6..f1dcbf415 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/ChaptersFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/chapter/ChaptersFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment;
+package de.danoeh.antennapod.ui.screen.chapter;
import android.app.Dialog;
import android.content.DialogInterface;
@@ -19,7 +19,6 @@ import androidx.recyclerview.widget.LinearLayoutManager;
import androidx.recyclerview.widget.RecyclerView;
import com.google.android.material.dialog.MaterialAlertDialogBuilder;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.adapter.ChaptersListAdapter;
import de.danoeh.antennapod.core.util.ChapterUtils;
import de.danoeh.antennapod.event.playback.PlaybackPositionEvent;
import de.danoeh.antennapod.model.feed.Chapter;
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/ChaptersListAdapter.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/chapter/ChaptersListAdapter.java
index 8f9a77f76..33e55a7e2 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/ChaptersListAdapter.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/chapter/ChaptersListAdapter.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.adapter;
+package de.danoeh.antennapod.ui.screen.chapter;
import android.content.Context;
import android.text.TextUtils;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/CompletedDownloadsFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/download/CompletedDownloadsFragment.java
index 9db4f585a..15be1e230 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/CompletedDownloadsFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/download/CompletedDownloadsFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment;
+package de.danoeh.antennapod.ui.screen.download;
import android.os.Bundle;
import android.util.Log;
@@ -16,31 +16,32 @@ import com.google.android.material.snackbar.Snackbar;
import com.leinardi.android.speeddial.SpeedDialView;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
-import de.danoeh.antennapod.adapter.EpisodeItemListAdapter;
-import de.danoeh.antennapod.adapter.actionbutton.DeleteActionButton;
+import de.danoeh.antennapod.ui.episodeslist.EpisodeItemListAdapter;
+import de.danoeh.antennapod.actionbutton.DeleteActionButton;
import de.danoeh.antennapod.event.DownloadLogEvent;
-import de.danoeh.antennapod.core.menuhandler.MenuItemUtils;
+import de.danoeh.antennapod.ui.MenuItemUtils;
+import de.danoeh.antennapod.ui.screen.SearchFragment;
import de.danoeh.antennapod.net.download.serviceinterface.FeedUpdateManager;
import de.danoeh.antennapod.storage.database.DBReader;
import de.danoeh.antennapod.core.util.FeedItemUtil;
-import de.danoeh.antennapod.dialog.ItemSortDialog;
+import de.danoeh.antennapod.ui.screen.feed.ItemSortDialog;
import de.danoeh.antennapod.event.EpisodeDownloadEvent;
import de.danoeh.antennapod.event.FeedItemEvent;
import de.danoeh.antennapod.event.PlayerStatusEvent;
import de.danoeh.antennapod.event.UnreadItemsUpdateEvent;
import de.danoeh.antennapod.event.playback.PlaybackPositionEvent;
-import de.danoeh.antennapod.fragment.actions.EpisodeMultiSelectActionHandler;
-import de.danoeh.antennapod.fragment.swipeactions.SwipeActions;
-import de.danoeh.antennapod.menuhandler.FeedItemMenuHandler;
+import de.danoeh.antennapod.ui.episodeslist.EpisodeMultiSelectActionHandler;
+import de.danoeh.antennapod.ui.swipeactions.SwipeActions;
+import de.danoeh.antennapod.ui.episodeslist.FeedItemMenuHandler;
import de.danoeh.antennapod.model.feed.FeedItem;
import de.danoeh.antennapod.model.feed.FeedItemFilter;
import de.danoeh.antennapod.model.feed.SortOrder;
import de.danoeh.antennapod.net.download.serviceinterface.DownloadServiceInterface;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
-import de.danoeh.antennapod.view.EmptyViewHandler;
-import de.danoeh.antennapod.view.EpisodeItemListRecyclerView;
-import de.danoeh.antennapod.view.LiftOnScrollListener;
-import de.danoeh.antennapod.view.viewholder.EpisodeItemViewHolder;
+import de.danoeh.antennapod.ui.view.EmptyViewHandler;
+import de.danoeh.antennapod.ui.episodeslist.EpisodeItemListRecyclerView;
+import de.danoeh.antennapod.ui.view.LiftOnScrollListener;
+import de.danoeh.antennapod.ui.episodeslist.EpisodeItemViewHolder;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.disposables.Disposable;
diff --git a/core/src/main/java/de/danoeh/antennapod/core/util/DownloadErrorLabel.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/download/DownloadErrorLabel.java
index 3d2558a9f..e5eedd54b 100644
--- a/core/src/main/java/de/danoeh/antennapod/core/util/DownloadErrorLabel.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/download/DownloadErrorLabel.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.core.util;
+package de.danoeh.antennapod.ui.screen.download;
import androidx.annotation.StringRes;
import de.danoeh.antennapod.core.BuildConfig;
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/DownloadLogAdapter.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/download/DownloadLogAdapter.java
index 84c9709bb..88472bcbf 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/DownloadLogAdapter.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/download/DownloadLogAdapter.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.adapter;
+package de.danoeh.antennapod.ui.screen.download;
import android.app.Activity;
import android.text.format.DateUtils;
@@ -9,15 +9,13 @@ import android.widget.BaseAdapter;
import android.widget.Toast;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
-import de.danoeh.antennapod.adapter.actionbutton.DownloadActionButton;
+import de.danoeh.antennapod.actionbutton.DownloadActionButton;
import de.danoeh.antennapod.net.download.serviceinterface.FeedUpdateManager;
import de.danoeh.antennapod.storage.database.DBReader;
-import de.danoeh.antennapod.core.util.DownloadErrorLabel;
import de.danoeh.antennapod.model.download.DownloadError;
import de.danoeh.antennapod.model.download.DownloadResult;
import de.danoeh.antennapod.model.feed.Feed;
import de.danoeh.antennapod.model.feed.FeedMedia;
-import de.danoeh.antennapod.view.viewholder.DownloadLogItemViewHolder;
import java.util.ArrayList;
import java.util.List;
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/DownloadLogDetailsDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/download/DownloadLogDetailsDialog.java
index 82e32aed3..a035f58ff 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/DownloadLogDetailsDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/download/DownloadLogDetailsDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui.screen.download;
import android.content.ClipData;
import android.content.ClipboardManager;
@@ -9,7 +9,6 @@ import androidx.annotation.NonNull;
import androidx.appcompat.app.AlertDialog;
import com.google.android.material.dialog.MaterialAlertDialogBuilder;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.core.util.DownloadErrorLabel;
import de.danoeh.antennapod.model.download.DownloadResult;
import de.danoeh.antennapod.storage.database.DBReader;
import de.danoeh.antennapod.event.MessageEvent;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/DownloadLogFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/download/DownloadLogFragment.java
index 54c6d1a9b..b6c8875e1 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/DownloadLogFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/download/DownloadLogFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment;
+package de.danoeh.antennapod.ui.screen.download;
import android.os.Bundle;
import android.util.Log;
@@ -12,14 +12,12 @@ import androidx.annotation.Nullable;
import com.google.android.material.appbar.MaterialToolbar;
import com.google.android.material.bottomsheet.BottomSheetDialogFragment;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.adapter.DownloadLogAdapter;
import de.danoeh.antennapod.event.DownloadLogEvent;
import de.danoeh.antennapod.storage.database.DBReader;
import de.danoeh.antennapod.storage.database.DBWriter;
import de.danoeh.antennapod.databinding.DownloadLogFragmentBinding;
-import de.danoeh.antennapod.dialog.DownloadLogDetailsDialog;
import de.danoeh.antennapod.model.download.DownloadResult;
-import de.danoeh.antennapod.view.EmptyViewHandler;
+import de.danoeh.antennapod.ui.view.EmptyViewHandler;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.disposables.Disposable;
diff --git a/app/src/main/java/de/danoeh/antennapod/view/viewholder/DownloadLogItemViewHolder.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/download/DownloadLogItemViewHolder.java
index ffb679830..97d368fac 100644
--- a/app/src/main/java/de/danoeh/antennapod/view/viewholder/DownloadLogItemViewHolder.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/download/DownloadLogItemViewHolder.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.view.viewholder;
+package de.danoeh.antennapod.ui.screen.download;
import android.content.Context;
import android.os.Build;
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/DrawerPreferencesDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/drawer/DrawerPreferencesDialog.java
index 8f174f207..4923df19c 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/DrawerPreferencesDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/drawer/DrawerPreferencesDialog.java
@@ -1,10 +1,10 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui.screen.drawer;
import android.content.Context;
import com.google.android.material.dialog.MaterialAlertDialogBuilder;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
-import de.danoeh.antennapod.fragment.NavDrawerFragment;
+import de.danoeh.antennapod.ui.screen.drawer.NavDrawerFragment;
import java.util.List;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/NavDrawerFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/drawer/NavDrawerFragment.java
index 49ef099f9..fabcaf652 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/NavDrawerFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/drawer/NavDrawerFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment;
+package de.danoeh.antennapod.ui.screen.drawer;
import android.app.Activity;
import android.content.Context;
@@ -34,6 +34,13 @@ import com.google.android.material.shape.MaterialShapeDrawable;
import com.google.android.material.shape.ShapeAppearanceModel;
import de.danoeh.antennapod.core.storage.EpisodeCleanupAlgorithmFactory;
+import de.danoeh.antennapod.ui.screen.AddFeedFragment;
+import de.danoeh.antennapod.ui.screen.AllEpisodesFragment;
+import de.danoeh.antennapod.ui.screen.InboxFragment;
+import de.danoeh.antennapod.ui.screen.PlaybackHistoryFragment;
+import de.danoeh.antennapod.ui.screen.queue.QueueFragment;
+import de.danoeh.antennapod.ui.screen.download.CompletedDownloadsFragment;
+import de.danoeh.antennapod.ui.screen.subscriptions.SubscriptionFragment;
import org.apache.commons.lang3.StringUtils;
import org.greenrobot.eventbus.EventBus;
import org.greenrobot.eventbus.Subscribe;
@@ -47,18 +54,16 @@ import java.util.Set;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
-import de.danoeh.antennapod.activity.PreferenceActivity;
-import de.danoeh.antennapod.adapter.NavListAdapter;
-import de.danoeh.antennapod.core.dialog.ConfirmationDialog;
-import de.danoeh.antennapod.core.menuhandler.MenuItemUtils;
+import de.danoeh.antennapod.ui.screen.preferences.PreferenceActivity;
+import de.danoeh.antennapod.core.util.ConfirmationDialog;
+import de.danoeh.antennapod.ui.MenuItemUtils;
import de.danoeh.antennapod.storage.database.DBReader;
import de.danoeh.antennapod.storage.database.DBWriter;
import de.danoeh.antennapod.storage.database.NavDrawerData;
-import de.danoeh.antennapod.dialog.DrawerPreferencesDialog;
-import de.danoeh.antennapod.dialog.RemoveFeedDialog;
-import de.danoeh.antennapod.dialog.RenameItemDialog;
-import de.danoeh.antennapod.dialog.SubscriptionsFilterDialog;
-import de.danoeh.antennapod.dialog.TagSettingsDialog;
+import de.danoeh.antennapod.ui.screen.feed.RemoveFeedDialog;
+import de.danoeh.antennapod.ui.screen.feed.RenameFeedDialog;
+import de.danoeh.antennapod.ui.screen.subscriptions.SubscriptionsFilterDialog;
+import de.danoeh.antennapod.ui.screen.feed.preferences.TagSettingsDialog;
import de.danoeh.antennapod.event.FeedListUpdateEvent;
import de.danoeh.antennapod.event.QueueEvent;
import de.danoeh.antennapod.event.UnreadItemsUpdateEvent;
@@ -66,7 +71,7 @@ import de.danoeh.antennapod.model.feed.Feed;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
import de.danoeh.antennapod.ui.appstartintent.MainActivityStarter;
import de.danoeh.antennapod.ui.common.ThemeUtils;
-import de.danoeh.antennapod.ui.home.HomeFragment;
+import de.danoeh.antennapod.ui.screen.home.HomeFragment;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.disposables.Disposable;
@@ -219,7 +224,7 @@ public class NavDrawerFragment extends Fragment implements SharedPreferences.OnS
.show(getChildFragmentManager(), TagSettingsDialog.TAG);
return true;
} else if (itemId == R.id.rename_item) {
- new RenameItemDialog(getActivity(), feed).show();
+ new RenameFeedDialog(getActivity(), feed).show();
return true;
} else if (itemId == R.id.remove_feed) {
RemoveFeedDialog.show(getContext(), feed, () -> {
@@ -237,7 +242,7 @@ public class NavDrawerFragment extends Fragment implements SharedPreferences.OnS
private boolean onTagContextMenuClicked(NavDrawerData.DrawerItem drawerItem, MenuItem item) {
final int itemId = item.getItemId();
if (itemId == R.id.rename_folder_item) {
- new RenameItemDialog(getActivity(), drawerItem).show();
+ new RenameFeedDialog(getActivity(), drawerItem).show();
return true;
}
return super.onContextItemSelected(item);
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/NavListAdapter.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/drawer/NavListAdapter.java
index 4c8e074a1..aaf872460 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/NavListAdapter.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/drawer/NavListAdapter.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.adapter;
+package de.danoeh.antennapod.ui.screen.drawer;
import android.app.Activity;
import android.content.Intent;
@@ -24,19 +24,18 @@ import androidx.recyclerview.widget.RecyclerView;
import com.bumptech.glide.Glide;
import com.bumptech.glide.request.RequestOptions;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.activity.PreferenceActivity;
-import de.danoeh.antennapod.fragment.AllEpisodesFragment;
-import de.danoeh.antennapod.fragment.CompletedDownloadsFragment;
-import de.danoeh.antennapod.fragment.InboxFragment;
+import de.danoeh.antennapod.ui.screen.preferences.PreferenceActivity;
+import de.danoeh.antennapod.ui.screen.AllEpisodesFragment;
+import de.danoeh.antennapod.ui.screen.download.CompletedDownloadsFragment;
+import de.danoeh.antennapod.ui.screen.InboxFragment;
import de.danoeh.antennapod.model.feed.Feed;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
import de.danoeh.antennapod.storage.database.NavDrawerData;
-import de.danoeh.antennapod.fragment.AddFeedFragment;
-import de.danoeh.antennapod.fragment.NavDrawerFragment;
-import de.danoeh.antennapod.fragment.PlaybackHistoryFragment;
-import de.danoeh.antennapod.fragment.QueueFragment;
-import de.danoeh.antennapod.fragment.SubscriptionFragment;
-import de.danoeh.antennapod.ui.home.HomeFragment;
+import de.danoeh.antennapod.ui.screen.AddFeedFragment;
+import de.danoeh.antennapod.ui.screen.PlaybackHistoryFragment;
+import de.danoeh.antennapod.ui.screen.queue.QueueFragment;
+import de.danoeh.antennapod.ui.screen.subscriptions.SubscriptionFragment;
+import de.danoeh.antennapod.ui.screen.home.HomeFragment;
import org.apache.commons.lang3.ArrayUtils;
import java.lang.ref.WeakReference;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/ItemFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/episode/ItemFragment.java
index 935d1f06d..b3a5cbbf0 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/ItemFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/episode/ItemFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment;
+package de.danoeh.antennapod.ui.screen.episode;
import android.content.Context;
import android.os.Build;
@@ -27,16 +27,16 @@ import com.skydoves.balloon.Balloon;
import com.skydoves.balloon.BalloonAnimation;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
-import de.danoeh.antennapod.adapter.actionbutton.CancelDownloadActionButton;
-import de.danoeh.antennapod.adapter.actionbutton.DeleteActionButton;
-import de.danoeh.antennapod.adapter.actionbutton.DownloadActionButton;
-import de.danoeh.antennapod.adapter.actionbutton.ItemActionButton;
-import de.danoeh.antennapod.adapter.actionbutton.MarkAsPlayedActionButton;
-import de.danoeh.antennapod.adapter.actionbutton.PauseActionButton;
-import de.danoeh.antennapod.adapter.actionbutton.PlayActionButton;
-import de.danoeh.antennapod.adapter.actionbutton.PlayLocalActionButton;
-import de.danoeh.antennapod.adapter.actionbutton.StreamActionButton;
-import de.danoeh.antennapod.adapter.actionbutton.VisitWebsiteActionButton;
+import de.danoeh.antennapod.actionbutton.CancelDownloadActionButton;
+import de.danoeh.antennapod.actionbutton.DeleteActionButton;
+import de.danoeh.antennapod.actionbutton.DownloadActionButton;
+import de.danoeh.antennapod.actionbutton.ItemActionButton;
+import de.danoeh.antennapod.actionbutton.MarkAsPlayedActionButton;
+import de.danoeh.antennapod.actionbutton.PauseActionButton;
+import de.danoeh.antennapod.actionbutton.PlayActionButton;
+import de.danoeh.antennapod.actionbutton.PlayLocalActionButton;
+import de.danoeh.antennapod.actionbutton.StreamActionButton;
+import de.danoeh.antennapod.actionbutton.VisitWebsiteActionButton;
import de.danoeh.antennapod.event.EpisodeDownloadEvent;
import de.danoeh.antennapod.playback.service.PlaybackStatus;
import de.danoeh.antennapod.event.FeedItemEvent;
@@ -53,9 +53,10 @@ 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.gui.ShownotesCleaner;
+import de.danoeh.antennapod.ui.cleaner.ShownotesCleaner;
import de.danoeh.antennapod.ui.episodes.ImageResourceUtils;
-import de.danoeh.antennapod.view.ShownotesWebView;
+import de.danoeh.antennapod.ui.screen.feed.FeedItemlistFragment;
+import de.danoeh.antennapod.ui.view.ShownotesWebView;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.disposables.Disposable;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/ItemPagerFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/episode/ItemPagerFragment.java
index 637d4c7ba..524066587 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/ItemPagerFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/episode/ItemPagerFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment;
+package de.danoeh.antennapod.ui.screen.episode;
import android.os.Bundle;
import android.view.LayoutInflater;
@@ -13,6 +13,7 @@ import androidx.fragment.app.Fragment;
import androidx.viewpager2.adapter.FragmentStateAdapter;
import androidx.viewpager2.widget.ViewPager2;
+import de.danoeh.antennapod.ui.screen.feed.FeedItemlistFragment;
import org.greenrobot.eventbus.EventBus;
import org.greenrobot.eventbus.Subscribe;
import org.greenrobot.eventbus.ThreadMode;
@@ -22,7 +23,7 @@ import de.danoeh.antennapod.activity.MainActivity;
import de.danoeh.antennapod.event.FeedItemEvent;
import de.danoeh.antennapod.model.feed.FeedItem;
import de.danoeh.antennapod.storage.database.DBReader;
-import de.danoeh.antennapod.menuhandler.FeedItemMenuHandler;
+import de.danoeh.antennapod.ui.episodeslist.FeedItemMenuHandler;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.disposables.Disposable;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/FeedInfoFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/FeedInfoFragment.java
index c93837851..3e7fd3cdc 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/FeedInfoFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/FeedInfoFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment;
+package de.danoeh.antennapod.ui.screen.feed;
import android.content.ActivityNotFoundException;
import android.content.ClipData;
@@ -34,18 +34,18 @@ import com.google.android.material.dialog.MaterialAlertDialogBuilder;
import com.google.android.material.snackbar.Snackbar;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
+import de.danoeh.antennapod.ui.TransitionEffect;
import de.danoeh.antennapod.storage.database.DBReader;
import de.danoeh.antennapod.storage.database.FeedDatabaseWriter;
import de.danoeh.antennapod.core.util.IntentUtils;
-import de.danoeh.antennapod.core.util.ShareUtils;
-import de.danoeh.antennapod.core.util.syndication.HtmlToPlainText;
-import de.danoeh.antennapod.dialog.EditUrlSettingsDialog;
+import de.danoeh.antennapod.ui.share.ShareUtils;
+import de.danoeh.antennapod.ui.cleaner.HtmlToPlainText;
import de.danoeh.antennapod.model.feed.Feed;
import de.danoeh.antennapod.model.feed.FeedFunding;
import de.danoeh.antennapod.ui.glide.FastBlurTransformation;
+import de.danoeh.antennapod.ui.screen.feed.preferences.EditUrlSettingsDialog;
import de.danoeh.antennapod.ui.statistics.StatisticsFragment;
import de.danoeh.antennapod.ui.statistics.feed.FeedStatisticsFragment;
-import de.danoeh.antennapod.view.ToolbarIconTintManager;
import io.reactivex.Completable;
import io.reactivex.Maybe;
import io.reactivex.MaybeOnSubscribe;
diff --git a/core/src/main/java/de/danoeh/antennapod/core/feed/FeedItemFilterGroup.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/FeedItemFilterGroup.java
index fbdf6b3a9..5cb0f36fd 100644
--- a/core/src/main/java/de/danoeh/antennapod/core/feed/FeedItemFilterGroup.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/FeedItemFilterGroup.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.core.feed;
+package de.danoeh.antennapod.ui.screen.feed;
import de.danoeh.antennapod.core.R;
import de.danoeh.antennapod.model.feed.FeedItemFilter;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/FeedItemlistFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/FeedItemlistFragment.java
index 1884012ea..7743f1cd9 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/FeedItemlistFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/FeedItemlistFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment;
+package de.danoeh.antennapod.ui.screen.feed;
import android.content.Context;
import android.content.res.Configuration;
@@ -26,7 +26,12 @@ import com.google.android.material.appbar.MaterialToolbar;
import com.google.android.material.snackbar.Snackbar;
import com.leinardi.android.speeddial.SpeedDialView;
+import de.danoeh.antennapod.ui.screen.episode.ItemPagerFragment;
+import de.danoeh.antennapod.ui.screen.SearchFragment;
+import de.danoeh.antennapod.ui.TransitionEffect;
import de.danoeh.antennapod.net.download.serviceinterface.FeedUpdateManager;
+import de.danoeh.antennapod.ui.screen.download.DownloadLogFragment;
+import de.danoeh.antennapod.ui.screen.feed.preferences.FeedSettingsFragment;
import org.apache.commons.lang3.StringUtils;
import org.apache.commons.lang3.Validate;
import org.greenrobot.eventbus.EventBus;
@@ -39,23 +44,20 @@ import java.util.concurrent.ExecutionException;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
-import de.danoeh.antennapod.adapter.EpisodeItemListAdapter;
+import de.danoeh.antennapod.ui.episodeslist.EpisodeItemListAdapter;
import de.danoeh.antennapod.event.FeedEvent;
-import de.danoeh.antennapod.core.menuhandler.MenuItemUtils;
+import de.danoeh.antennapod.ui.MenuItemUtils;
import de.danoeh.antennapod.storage.database.DBReader;
import de.danoeh.antennapod.storage.database.DBWriter;
import de.danoeh.antennapod.storage.database.FeedItemPermutors;
import de.danoeh.antennapod.core.util.FeedItemUtil;
import de.danoeh.antennapod.core.util.IntentUtils;
-import de.danoeh.antennapod.core.util.ShareUtils;
-import de.danoeh.antennapod.core.util.gui.MoreContentListFooterUtil;
+import de.danoeh.antennapod.ui.share.ShareUtils;
+import de.danoeh.antennapod.ui.episodeslist.MoreContentListFooterUtil;
import de.danoeh.antennapod.databinding.FeedItemListFragmentBinding;
import de.danoeh.antennapod.databinding.MultiSelectSpeedDialBinding;
-import de.danoeh.antennapod.dialog.DownloadLogDetailsDialog;
-import de.danoeh.antennapod.dialog.FeedItemFilterDialog;
-import de.danoeh.antennapod.dialog.ItemSortDialog;
-import de.danoeh.antennapod.dialog.RemoveFeedDialog;
-import de.danoeh.antennapod.dialog.RenameItemDialog;
+import de.danoeh.antennapod.ui.screen.download.DownloadLogDetailsDialog;
+import de.danoeh.antennapod.ui.FeedItemFilterDialog;
import de.danoeh.antennapod.event.EpisodeDownloadEvent;
import de.danoeh.antennapod.event.FavoritesEvent;
import de.danoeh.antennapod.event.FeedItemEvent;
@@ -65,9 +67,9 @@ import de.danoeh.antennapod.event.PlayerStatusEvent;
import de.danoeh.antennapod.event.QueueEvent;
import de.danoeh.antennapod.event.UnreadItemsUpdateEvent;
import de.danoeh.antennapod.event.playback.PlaybackPositionEvent;
-import de.danoeh.antennapod.fragment.actions.EpisodeMultiSelectActionHandler;
-import de.danoeh.antennapod.fragment.swipeactions.SwipeActions;
-import de.danoeh.antennapod.menuhandler.FeedItemMenuHandler;
+import de.danoeh.antennapod.ui.episodeslist.EpisodeMultiSelectActionHandler;
+import de.danoeh.antennapod.ui.swipeactions.SwipeActions;
+import de.danoeh.antennapod.ui.episodeslist.FeedItemMenuHandler;
import de.danoeh.antennapod.model.download.DownloadResult;
import de.danoeh.antennapod.model.feed.Feed;
import de.danoeh.antennapod.model.feed.FeedItem;
@@ -75,8 +77,7 @@ import de.danoeh.antennapod.model.feed.FeedItemFilter;
import de.danoeh.antennapod.model.feed.SortOrder;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
import de.danoeh.antennapod.ui.glide.FastBlurTransformation;
-import de.danoeh.antennapod.view.ToolbarIconTintManager;
-import de.danoeh.antennapod.view.viewholder.EpisodeItemViewHolder;
+import de.danoeh.antennapod.ui.episodeslist.EpisodeItemViewHolder;
import io.reactivex.Maybe;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
@@ -289,7 +290,7 @@ public class FeedItemlistFragment extends Fragment implements AdapterView.OnItem
} else if (item.getItemId() == R.id.sort_items) {
SingleFeedSortDialog.newInstance(feed).show(getChildFragmentManager(), "SortDialog");
} else if (item.getItemId() == R.id.rename_item) {
- new RenameItemDialog(getActivity(), feed).show();
+ new RenameFeedDialog(getActivity(), feed).show();
} else if (item.getItemId() == R.id.remove_feed) {
RemoveFeedDialog.show(getContext(), feed, () -> {
((MainActivity) getActivity()).loadFragment(UserPreferences.getDefaultPage(), null);
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/ItemFilterDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/ItemFilterDialog.java
index 359c513af..8dbcce699 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/ItemFilterDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/ItemFilterDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui.screen.feed;
import android.app.Dialog;
import android.os.Bundle;
@@ -23,7 +23,6 @@ import java.util.HashSet;
import java.util.Set;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.core.feed.FeedItemFilterGroup;
import de.danoeh.antennapod.databinding.FilterDialogBinding;
import de.danoeh.antennapod.databinding.FilterDialogRowBinding;
import de.danoeh.antennapod.model.feed.FeedItemFilter;
@@ -119,5 +118,5 @@ public abstract class ItemFilterDialog extends BottomSheetDialogFragment {
return newFilterValues;
}
- abstract void onFilterChanged(Set<String> newFilterValues);
+ public abstract void onFilterChanged(Set<String> newFilterValues);
}
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/ItemSortDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/ItemSortDialog.java
index cd6cc4b0a..bb68477df 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/ItemSortDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/ItemSortDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui.screen.feed;
import android.app.Dialog;
import android.os.Bundle;
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/RemoveFeedDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/RemoveFeedDialog.java
index ffa374b6f..415948a81 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/RemoveFeedDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/RemoveFeedDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui.screen.feed;
import android.app.ProgressDialog;
import android.content.Context;
@@ -11,7 +11,7 @@ import java.util.Collections;
import java.util.List;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.core.dialog.ConfirmationDialog;
+import de.danoeh.antennapod.core.util.ConfirmationDialog;
import de.danoeh.antennapod.model.feed.Feed;
import de.danoeh.antennapod.storage.database.DBWriter;
import io.reactivex.Completable;
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/RenameItemDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/RenameFeedDialog.java
index bbe6fd16c..4bc63f732 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/RenameItemDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/RenameFeedDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui.screen.feed;
import android.app.Activity;
@@ -16,18 +16,18 @@ import de.danoeh.antennapod.storage.database.DBWriter;
import de.danoeh.antennapod.databinding.EditTextDialogBinding;
import de.danoeh.antennapod.model.feed.FeedPreferences;
-public class RenameItemDialog {
+public class RenameFeedDialog {
private final WeakReference<Activity> activityRef;
private Feed feed = null;
private NavDrawerData.DrawerItem drawerItem = null;
- public RenameItemDialog(Activity activity, Feed feed) {
+ public RenameFeedDialog(Activity activity, Feed feed) {
this.activityRef = new WeakReference<>(activity);
this.feed = feed;
}
- public RenameItemDialog(Activity activity, NavDrawerData.DrawerItem drawerItem) {
+ public RenameFeedDialog(Activity activity, NavDrawerData.DrawerItem drawerItem) {
this.activityRef = new WeakReference<>(activity);
this.drawerItem = drawerItem;
}
diff --git a/app/src/main/java/de/danoeh/antennapod/view/ToolbarIconTintManager.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/ToolbarIconTintManager.java
index 67c2e2555..e158053d0 100644
--- a/app/src/main/java/de/danoeh/antennapod/view/ToolbarIconTintManager.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/ToolbarIconTintManager.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.view;
+package de.danoeh.antennapod.ui.screen.feed;
import android.content.Context;
import android.graphics.PorterDuff.Mode;
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/EditUrlSettingsDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/preferences/EditUrlSettingsDialog.java
index 67c5d85cf..767de3ecc 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/EditUrlSettingsDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/preferences/EditUrlSettingsDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui.screen.feed.preferences;
import android.app.Activity;
import android.os.CountDownTimer;
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/EpisodeFilterDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/preferences/EpisodeFilterDialog.java
index 220650f0f..f07d37fec 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/EpisodeFilterDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/preferences/EpisodeFilterDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui.screen.feed.preferences;
import android.content.Context;
import android.content.DialogInterface;
@@ -7,10 +7,10 @@ import android.view.LayoutInflater;
import androidx.recyclerview.widget.GridLayoutManager;
import com.google.android.material.dialog.MaterialAlertDialogBuilder;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.adapter.SimpleChipAdapter;
+import de.danoeh.antennapod.ui.SimpleChipAdapter;
import de.danoeh.antennapod.databinding.EpisodeFilterDialogBinding;
import de.danoeh.antennapod.model.feed.FeedFilter;
-import de.danoeh.antennapod.view.ItemOffsetDecoration;
+import de.danoeh.antennapod.ui.view.ItemOffsetDecoration;
import java.util.List;
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/FeedPreferenceSkipDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/preferences/FeedPreferenceSkipDialog.java
index 77c9ff67e..bac336d2f 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/FeedPreferenceSkipDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/preferences/FeedPreferenceSkipDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui.screen.feed.preferences;
import android.content.Context;
import android.view.View;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/FeedSettingsFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/preferences/FeedSettingsFragment.java
index 69cfb0087..4ac844479 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/FeedSettingsFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/preferences/FeedSettingsFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment;
+package de.danoeh.antennapod.ui.screen.feed.preferences;
import android.Manifest;
import android.content.Intent;
@@ -38,9 +38,6 @@ import de.danoeh.antennapod.net.download.serviceinterface.FeedUpdateManager;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
import de.danoeh.antennapod.storage.database.DBReader;
import de.danoeh.antennapod.storage.database.DBWriter;
-import de.danoeh.antennapod.dialog.EpisodeFilterDialog;
-import de.danoeh.antennapod.dialog.FeedPreferenceSkipDialog;
-import de.danoeh.antennapod.dialog.TagSettingsDialog;
import de.danoeh.antennapod.ui.preferences.screen.synchronization.AuthenticationDialog;
import io.reactivex.Maybe;
import io.reactivex.MaybeOnSubscribe;
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/SkipPreferenceDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/preferences/SkipPreferenceDialog.java
index a5eca4bc2..983e265c1 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/SkipPreferenceDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/preferences/SkipPreferenceDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui.screen.feed.preferences;
import android.content.Context;
import android.widget.TextView;
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/TagSettingsDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/preferences/TagSettingsDialog.java
index 8112c0955..accc5cc60 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/TagSettingsDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/preferences/TagSettingsDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui.screen.feed.preferences;
import android.app.Dialog;
import android.os.Bundle;
@@ -21,7 +21,7 @@ import java.util.List;
import java.util.Set;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.adapter.SimpleChipAdapter;
+import de.danoeh.antennapod.ui.SimpleChipAdapter;
import de.danoeh.antennapod.storage.database.DBReader;
import de.danoeh.antennapod.storage.database.DBWriter;
import de.danoeh.antennapod.storage.database.NavDrawerData;
@@ -29,7 +29,7 @@ import de.danoeh.antennapod.databinding.EditTagsDialogBinding;
import de.danoeh.antennapod.model.feed.FeedCounter;
import de.danoeh.antennapod.model.feed.FeedOrder;
import de.danoeh.antennapod.model.feed.FeedPreferences;
-import de.danoeh.antennapod.view.ItemOffsetDecoration;
+import de.danoeh.antennapod.ui.view.ItemOffsetDecoration;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.schedulers.Schedulers;
diff --git a/app/src/main/java/de/danoeh/antennapod/preferences/VolumeAdaptationPreference.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/preferences/VolumeAdaptationPreference.java
index a4ed402ed..70f5da5fc 100644
--- a/app/src/main/java/de/danoeh/antennapod/preferences/VolumeAdaptationPreference.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/feed/preferences/VolumeAdaptationPreference.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.preferences;
+package de.danoeh.antennapod.ui.screen.feed.preferences;
import android.content.Context;
import android.util.AttributeSet;
diff --git a/app/src/main/java/de/danoeh/antennapod/ui/home/HomeFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/home/HomeFragment.java
index 90d4817da..bcbc2675a 100644
--- a/app/src/main/java/de/danoeh/antennapod/ui/home/HomeFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/home/HomeFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.ui.home;
+package de.danoeh.antennapod.ui.screen.home;
import android.Manifest;
import android.content.Context;
@@ -21,6 +21,13 @@ import androidx.fragment.app.FragmentContainerView;
import de.danoeh.antennapod.net.download.serviceinterface.FeedUpdateManager;
import de.danoeh.antennapod.ui.echo.EchoConfig;
+import de.danoeh.antennapod.ui.screen.home.sections.AllowNotificationsSection;
+import de.danoeh.antennapod.ui.screen.home.sections.DownloadsSection;
+import de.danoeh.antennapod.ui.screen.home.sections.EchoSection;
+import de.danoeh.antennapod.ui.screen.home.sections.EpisodesSurpriseSection;
+import de.danoeh.antennapod.ui.screen.home.sections.InboxSection;
+import de.danoeh.antennapod.ui.screen.home.sections.QueueSection;
+import de.danoeh.antennapod.ui.screen.home.sections.SubscriptionsSection;
import org.greenrobot.eventbus.EventBus;
import org.greenrobot.eventbus.Subscribe;
import org.greenrobot.eventbus.ThreadMode;
@@ -36,16 +43,9 @@ import de.danoeh.antennapod.storage.database.DBReader;
import de.danoeh.antennapod.databinding.HomeFragmentBinding;
import de.danoeh.antennapod.event.FeedListUpdateEvent;
import de.danoeh.antennapod.event.FeedUpdateRunningEvent;
-import de.danoeh.antennapod.fragment.SearchFragment;
+import de.danoeh.antennapod.ui.screen.SearchFragment;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
-import de.danoeh.antennapod.ui.home.sections.AllowNotificationsSection;
-import de.danoeh.antennapod.ui.home.sections.DownloadsSection;
-import de.danoeh.antennapod.ui.home.sections.EchoSection;
-import de.danoeh.antennapod.ui.home.sections.EpisodesSurpriseSection;
-import de.danoeh.antennapod.ui.home.sections.InboxSection;
-import de.danoeh.antennapod.ui.home.sections.QueueSection;
-import de.danoeh.antennapod.ui.home.sections.SubscriptionsSection;
-import de.danoeh.antennapod.view.LiftOnScrollListener;
+import de.danoeh.antennapod.ui.view.LiftOnScrollListener;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.disposables.Disposable;
diff --git a/app/src/main/java/de/danoeh/antennapod/ui/home/HomeSection.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/home/HomeSection.java
index 03036d267..908267f47 100644
--- a/app/src/main/java/de/danoeh/antennapod/ui/home/HomeSection.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/home/HomeSection.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.ui.home;
+package de.danoeh.antennapod.ui.screen.home;
import android.os.Bundle;
import android.text.TextUtils;
@@ -11,12 +11,12 @@ import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.fragment.app.Fragment;
import androidx.recyclerview.widget.DefaultItemAnimator;
-import de.danoeh.antennapod.adapter.EpisodeItemListAdapter;
-import de.danoeh.antennapod.adapter.HorizontalFeedListAdapter;
-import de.danoeh.antennapod.adapter.HorizontalItemListAdapter;
+import de.danoeh.antennapod.ui.episodeslist.EpisodeItemListAdapter;
+import de.danoeh.antennapod.ui.screen.subscriptions.HorizontalFeedListAdapter;
+import de.danoeh.antennapod.ui.episodeslist.HorizontalItemListAdapter;
import de.danoeh.antennapod.databinding.HomeSectionBinding;
-import de.danoeh.antennapod.menuhandler.FeedItemMenuHandler;
-import de.danoeh.antennapod.menuhandler.FeedMenuHandler;
+import de.danoeh.antennapod.ui.episodeslist.FeedItemMenuHandler;
+import de.danoeh.antennapod.ui.screen.subscriptions.FeedMenuHandler;
import de.danoeh.antennapod.model.feed.Feed;
import de.danoeh.antennapod.model.feed.FeedItem;
import org.greenrobot.eventbus.EventBus;
diff --git a/app/src/main/java/de/danoeh/antennapod/ui/home/HomeSectionsSettingsDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/home/HomeSectionsSettingsDialog.java
index e651aea48..3238c299c 100644
--- a/app/src/main/java/de/danoeh/antennapod/ui/home/HomeSectionsSettingsDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/home/HomeSectionsSettingsDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.ui.home;
+package de.danoeh.antennapod.ui.screen.home;
import android.content.Context;
import android.content.DialogInterface;
diff --git a/app/src/main/java/de/danoeh/antennapod/ui/home/sections/AllowNotificationsSection.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/home/sections/AllowNotificationsSection.java
index 0a0d30485..0b26865c8 100644
--- a/app/src/main/java/de/danoeh/antennapod/ui/home/sections/AllowNotificationsSection.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/home/sections/AllowNotificationsSection.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.ui.home.sections;
+package de.danoeh.antennapod.ui.screen.home.sections;
import android.Manifest;
import android.content.Context;
@@ -20,7 +20,7 @@ import com.google.android.material.dialog.MaterialAlertDialogBuilder;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
import de.danoeh.antennapod.databinding.HomeSectionNotificationBinding;
-import de.danoeh.antennapod.ui.home.HomeFragment;
+import de.danoeh.antennapod.ui.screen.home.HomeFragment;
public class AllowNotificationsSection extends Fragment {
HomeSectionNotificationBinding viewBinding;
diff --git a/app/src/main/java/de/danoeh/antennapod/ui/home/sections/DownloadsSection.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/home/sections/DownloadsSection.java
index 9540bc2e3..4dc34a80e 100644
--- a/app/src/main/java/de/danoeh/antennapod/ui/home/sections/DownloadsSection.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/home/sections/DownloadsSection.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.ui.home.sections;
+package de.danoeh.antennapod.ui.screen.home.sections;
import android.os.Bundle;
import android.util.Log;
@@ -12,21 +12,21 @@ import androidx.recyclerview.widget.LinearLayoutManager;
import androidx.recyclerview.widget.RecyclerView;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
-import de.danoeh.antennapod.adapter.EpisodeItemListAdapter;
+import de.danoeh.antennapod.ui.episodeslist.EpisodeItemListAdapter;
import de.danoeh.antennapod.event.DownloadLogEvent;
-import de.danoeh.antennapod.core.menuhandler.MenuItemUtils;
+import de.danoeh.antennapod.ui.MenuItemUtils;
import de.danoeh.antennapod.storage.database.DBReader;
import de.danoeh.antennapod.event.FeedItemEvent;
import de.danoeh.antennapod.event.PlayerStatusEvent;
import de.danoeh.antennapod.event.playback.PlaybackPositionEvent;
-import de.danoeh.antennapod.fragment.CompletedDownloadsFragment;
-import de.danoeh.antennapod.fragment.swipeactions.SwipeActions;
+import de.danoeh.antennapod.ui.screen.download.CompletedDownloadsFragment;
+import de.danoeh.antennapod.ui.swipeactions.SwipeActions;
import de.danoeh.antennapod.model.feed.FeedItem;
import de.danoeh.antennapod.model.feed.FeedItemFilter;
import de.danoeh.antennapod.model.feed.SortOrder;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
-import de.danoeh.antennapod.ui.home.HomeSection;
-import de.danoeh.antennapod.view.viewholder.EpisodeItemViewHolder;
+import de.danoeh.antennapod.ui.screen.home.HomeSection;
+import de.danoeh.antennapod.ui.episodeslist.EpisodeItemViewHolder;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.disposables.Disposable;
diff --git a/app/src/main/java/de/danoeh/antennapod/ui/home/sections/EchoSection.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/home/sections/EchoSection.java
index 28ff05512..d8df470f0 100644
--- a/app/src/main/java/de/danoeh/antennapod/ui/home/sections/EchoSection.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/home/sections/EchoSection.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.ui.home.sections;
+package de.danoeh.antennapod.ui.screen.home.sections;
import android.content.Context;
import android.content.Intent;
@@ -16,7 +16,7 @@ import de.danoeh.antennapod.storage.database.DBReader;
import de.danoeh.antennapod.storage.database.StatisticsItem;
import de.danoeh.antennapod.ui.echo.EchoActivity;
import de.danoeh.antennapod.ui.echo.EchoConfig;
-import de.danoeh.antennapod.ui.home.HomeFragment;
+import de.danoeh.antennapod.ui.screen.home.HomeFragment;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.disposables.Disposable;
diff --git a/app/src/main/java/de/danoeh/antennapod/ui/home/sections/EpisodesSurpriseSection.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/home/sections/EpisodesSurpriseSection.java
index f93e28cbd..451a0aedc 100644
--- a/app/src/main/java/de/danoeh/antennapod/ui/home/sections/EpisodesSurpriseSection.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/home/sections/EpisodesSurpriseSection.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.ui.home.sections;
+package de.danoeh.antennapod.ui.screen.home.sections;
import android.os.Bundle;
import android.util.Log;
@@ -12,18 +12,18 @@ import androidx.recyclerview.widget.LinearLayoutManager;
import androidx.recyclerview.widget.RecyclerView;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
-import de.danoeh.antennapod.adapter.HorizontalItemListAdapter;
-import de.danoeh.antennapod.core.menuhandler.MenuItemUtils;
+import de.danoeh.antennapod.ui.episodeslist.HorizontalItemListAdapter;
+import de.danoeh.antennapod.ui.MenuItemUtils;
import de.danoeh.antennapod.storage.database.DBReader;
import de.danoeh.antennapod.core.util.FeedItemUtil;
import de.danoeh.antennapod.event.EpisodeDownloadEvent;
import de.danoeh.antennapod.event.FeedItemEvent;
import de.danoeh.antennapod.event.PlayerStatusEvent;
import de.danoeh.antennapod.event.playback.PlaybackPositionEvent;
-import de.danoeh.antennapod.fragment.AllEpisodesFragment;
+import de.danoeh.antennapod.ui.screen.AllEpisodesFragment;
import de.danoeh.antennapod.model.feed.FeedItem;
-import de.danoeh.antennapod.ui.home.HomeSection;
-import de.danoeh.antennapod.view.viewholder.HorizontalItemViewHolder;
+import de.danoeh.antennapod.ui.screen.home.HomeSection;
+import de.danoeh.antennapod.ui.episodeslist.HorizontalItemViewHolder;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.disposables.Disposable;
diff --git a/app/src/main/java/de/danoeh/antennapod/ui/home/sections/InboxSection.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/home/sections/InboxSection.java
index e5a72f72c..de6f6bef4 100644
--- a/app/src/main/java/de/danoeh/antennapod/ui/home/sections/InboxSection.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/home/sections/InboxSection.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.ui.home.sections;
+package de.danoeh.antennapod.ui.screen.home.sections;
import android.os.Bundle;
import android.util.Log;
@@ -13,20 +13,20 @@ import androidx.recyclerview.widget.LinearLayoutManager;
import androidx.recyclerview.widget.RecyclerView;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
-import de.danoeh.antennapod.adapter.EpisodeItemListAdapter;
-import de.danoeh.antennapod.core.menuhandler.MenuItemUtils;
+import de.danoeh.antennapod.ui.episodeslist.EpisodeItemListAdapter;
+import de.danoeh.antennapod.ui.MenuItemUtils;
import de.danoeh.antennapod.storage.database.DBReader;
import de.danoeh.antennapod.core.util.FeedItemUtil;
import de.danoeh.antennapod.event.EpisodeDownloadEvent;
import de.danoeh.antennapod.event.FeedItemEvent;
import de.danoeh.antennapod.event.FeedListUpdateEvent;
import de.danoeh.antennapod.event.UnreadItemsUpdateEvent;
-import de.danoeh.antennapod.fragment.InboxFragment;
-import de.danoeh.antennapod.fragment.swipeactions.SwipeActions;
+import de.danoeh.antennapod.ui.screen.InboxFragment;
+import de.danoeh.antennapod.ui.swipeactions.SwipeActions;
import de.danoeh.antennapod.model.feed.FeedItem;
import de.danoeh.antennapod.model.feed.FeedItemFilter;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
-import de.danoeh.antennapod.ui.home.HomeSection;
+import de.danoeh.antennapod.ui.screen.home.HomeSection;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.disposables.Disposable;
diff --git a/app/src/main/java/de/danoeh/antennapod/ui/home/sections/QueueSection.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/home/sections/QueueSection.java
index 4344f967c..57d896ae9 100644
--- a/app/src/main/java/de/danoeh/antennapod/ui/home/sections/QueueSection.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/home/sections/QueueSection.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.ui.home.sections;
+package de.danoeh.antennapod.ui.screen.home.sections;
import android.os.Bundle;
import android.util.Log;
@@ -12,8 +12,8 @@ import androidx.recyclerview.widget.LinearLayoutManager;
import androidx.recyclerview.widget.RecyclerView;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
-import de.danoeh.antennapod.adapter.HorizontalItemListAdapter;
-import de.danoeh.antennapod.core.menuhandler.MenuItemUtils;
+import de.danoeh.antennapod.ui.episodeslist.HorizontalItemListAdapter;
+import de.danoeh.antennapod.ui.MenuItemUtils;
import de.danoeh.antennapod.storage.database.DBReader;
import de.danoeh.antennapod.core.util.FeedItemUtil;
import de.danoeh.antennapod.event.EpisodeDownloadEvent;
@@ -21,10 +21,10 @@ import de.danoeh.antennapod.event.FeedItemEvent;
import de.danoeh.antennapod.event.PlayerStatusEvent;
import de.danoeh.antennapod.event.QueueEvent;
import de.danoeh.antennapod.event.playback.PlaybackPositionEvent;
-import de.danoeh.antennapod.fragment.QueueFragment;
+import de.danoeh.antennapod.ui.screen.queue.QueueFragment;
import de.danoeh.antennapod.model.feed.FeedItem;
-import de.danoeh.antennapod.ui.home.HomeSection;
-import de.danoeh.antennapod.view.viewholder.HorizontalItemViewHolder;
+import de.danoeh.antennapod.ui.screen.home.HomeSection;
+import de.danoeh.antennapod.ui.episodeslist.HorizontalItemViewHolder;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.disposables.Disposable;
diff --git a/app/src/main/java/de/danoeh/antennapod/ui/home/sections/SubscriptionsSection.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/home/sections/SubscriptionsSection.java
index b97254d49..a37d1367f 100644
--- a/app/src/main/java/de/danoeh/antennapod/ui/home/sections/SubscriptionsSection.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/home/sections/SubscriptionsSection.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.ui.home.sections;
+package de.danoeh.antennapod.ui.screen.home.sections;
import android.content.Context;
import android.content.SharedPreferences;
@@ -14,13 +14,13 @@ import androidx.recyclerview.widget.LinearLayoutManager;
import androidx.recyclerview.widget.RecyclerView;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
-import de.danoeh.antennapod.adapter.HorizontalFeedListAdapter;
-import de.danoeh.antennapod.core.menuhandler.MenuItemUtils;
+import de.danoeh.antennapod.ui.screen.subscriptions.HorizontalFeedListAdapter;
+import de.danoeh.antennapod.ui.MenuItemUtils;
import de.danoeh.antennapod.storage.database.DBReader;
import de.danoeh.antennapod.event.FeedListUpdateEvent;
-import de.danoeh.antennapod.fragment.SubscriptionFragment;
+import de.danoeh.antennapod.ui.screen.subscriptions.SubscriptionFragment;
import de.danoeh.antennapod.model.feed.Feed;
-import de.danoeh.antennapod.ui.home.HomeSection;
+import de.danoeh.antennapod.ui.screen.home.HomeSection;
import de.danoeh.antennapod.ui.statistics.StatisticsFragment;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
diff --git a/core/src/main/java/de/danoeh/antennapod/core/util/syndication/FeedDiscoverer.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/onlinefeedview/FeedDiscoverer.java
index 316608f2f..1109c86d8 100644
--- a/core/src/main/java/de/danoeh/antennapod/core/util/syndication/FeedDiscoverer.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/onlinefeedview/FeedDiscoverer.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.core.util.syndication;
+package de.danoeh.antennapod.ui.screen.onlinefeedview;
import android.net.Uri;
import androidx.collection.ArrayMap;
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/FeedItemlistDescriptionAdapter.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/onlinefeedview/FeedItemlistDescriptionAdapter.java
index b55f2a6bc..f46d786cf 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/FeedItemlistDescriptionAdapter.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/onlinefeedview/FeedItemlistDescriptionAdapter.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.adapter;
+package de.danoeh.antennapod.ui.screen.onlinefeedview;
import android.content.Context;
import android.view.LayoutInflater;
@@ -20,8 +20,8 @@ import de.danoeh.antennapod.playback.service.PlaybackService;
import de.danoeh.antennapod.playback.service.PlaybackServiceStarter;
import de.danoeh.antennapod.ui.common.DateFormatter;
import de.danoeh.antennapod.model.playback.Playable;
-import de.danoeh.antennapod.core.util.syndication.HtmlToPlainText;
-import de.danoeh.antennapod.dialog.StreamingConfirmationDialog;
+import de.danoeh.antennapod.ui.cleaner.HtmlToPlainText;
+import de.danoeh.antennapod.ui.StreamingConfirmationDialog;
import java.util.List;
diff --git a/app/src/main/java/de/danoeh/antennapod/activity/OnlineFeedViewActivity.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/onlinefeedview/OnlineFeedViewActivity.java
index 1f3963d46..42050e718 100644
--- a/app/src/main/java/de/danoeh/antennapod/activity/OnlineFeedViewActivity.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/onlinefeedview/OnlineFeedViewActivity.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.activity;
+package de.danoeh.antennapod.ui.screen.onlinefeedview;
import android.app.Dialog;
import android.content.Context;
@@ -27,7 +27,6 @@ import com.bumptech.glide.request.RequestOptions;
import com.google.android.material.snackbar.Snackbar;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.adapter.FeedItemlistDescriptionAdapter;
import de.danoeh.antennapod.net.download.service.feed.remote.Downloader;
import de.danoeh.antennapod.net.download.service.feed.remote.HttpDownloader;
import de.danoeh.antennapod.ui.appstartintent.MainActivityStarter;
@@ -36,7 +35,7 @@ import de.danoeh.antennapod.net.download.serviceinterface.DownloadRequestCreator
import de.danoeh.antennapod.net.discovery.FeedUrlNotFoundException;
import de.danoeh.antennapod.storage.database.FeedDatabaseWriter;
import de.danoeh.antennapod.playback.service.PlaybackServiceInterface;
-import de.danoeh.antennapod.core.util.DownloadErrorLabel;
+import de.danoeh.antennapod.ui.screen.download.DownloadErrorLabel;
import de.danoeh.antennapod.databinding.EditTextDialogBinding;
import de.danoeh.antennapod.databinding.OnlinefeedviewHeaderBinding;
import de.danoeh.antennapod.event.EpisodeDownloadEvent;
@@ -57,8 +56,7 @@ import de.danoeh.antennapod.parser.feed.FeedHandlerResult;
import de.danoeh.antennapod.model.download.DownloadError;
import de.danoeh.antennapod.core.util.IntentUtils;
import de.danoeh.antennapod.net.common.UrlChecker;
-import de.danoeh.antennapod.core.util.syndication.FeedDiscoverer;
-import de.danoeh.antennapod.core.util.syndication.HtmlToPlainText;
+import de.danoeh.antennapod.ui.cleaner.HtmlToPlainText;
import de.danoeh.antennapod.databinding.OnlinefeedviewActivityBinding;
import de.danoeh.antennapod.model.feed.Feed;
import de.danoeh.antennapod.model.feed.FeedPreferences;
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/MediaPlayerErrorDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/MediaPlayerErrorDialog.java
index 8425e0bfa..62dff00fd 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/MediaPlayerErrorDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/MediaPlayerErrorDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui.screen.playback;
import android.app.Activity;
import android.text.Spannable;
diff --git a/app/src/main/java/de/danoeh/antennapod/view/PlayButton.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/PlayButton.java
index 04b277fb4..fbd791e71 100644
--- a/app/src/main/java/de/danoeh/antennapod/view/PlayButton.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/PlayButton.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.view;
+package de.danoeh.antennapod.ui.screen.playback;
import android.content.Context;
import android.util.AttributeSet;
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/PlaybackControlsDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/PlaybackControlsDialog.java
index 97b161955..b46c5e80c 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/PlaybackControlsDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/PlaybackControlsDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui.screen.playback;
import android.app.Dialog;
import android.os.Bundle;
diff --git a/app/src/main/java/de/danoeh/antennapod/activity/PlaybackSpeedDialogActivity.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/PlaybackSpeedDialogActivity.java
index 37f13272a..9d73e81a7 100644
--- a/app/src/main/java/de/danoeh/antennapod/activity/PlaybackSpeedDialogActivity.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/PlaybackSpeedDialogActivity.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.activity;
+package de.danoeh.antennapod.ui.screen.playback;
import androidx.annotation.NonNull;
import androidx.appcompat.app.AppCompatActivity;
@@ -7,7 +7,7 @@ import android.content.DialogInterface;
import android.os.Bundle;
import de.danoeh.antennapod.ui.common.ThemeSwitcher;
-import de.danoeh.antennapod.dialog.VariableSpeedDialog;
+import de.danoeh.antennapod.ui.screen.playback.VariableSpeedDialog;
public class PlaybackSpeedDialogActivity extends AppCompatActivity {
diff --git a/app/src/main/java/de/danoeh/antennapod/view/PlaybackSpeedSeekBar.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/PlaybackSpeedSeekBar.java
index 33f0d47b8..c65d3656c 100644
--- a/app/src/main/java/de/danoeh/antennapod/view/PlaybackSpeedSeekBar.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/PlaybackSpeedSeekBar.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.view;
+package de.danoeh.antennapod.ui.screen.playback;
import android.content.Context;
import android.util.AttributeSet;
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/SleepTimerDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/SleepTimerDialog.java
index 5525ee8c2..911460d58 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/SleepTimerDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/SleepTimerDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui.screen.playback;
import android.app.Activity;
import android.app.Dialog;
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/TimeRangeDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/TimeRangeDialog.java
index 1d84c7c22..683c162fc 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/TimeRangeDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/TimeRangeDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui.screen.playback;
import android.content.Context;
import android.graphics.Canvas;
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/VariableSpeedDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/VariableSpeedDialog.java
index ee5777d35..8343e933a 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/VariableSpeedDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/VariableSpeedDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui.screen.playback;
import android.os.Bundle;
import android.os.Handler;
@@ -19,8 +19,7 @@ import de.danoeh.antennapod.R;
import de.danoeh.antennapod.event.playback.SpeedChangedEvent;
import de.danoeh.antennapod.playback.service.PlaybackController;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
-import de.danoeh.antennapod.view.ItemOffsetDecoration;
-import de.danoeh.antennapod.view.PlaybackSpeedSeekBar;
+import de.danoeh.antennapod.ui.view.ItemOffsetDecoration;
import org.greenrobot.eventbus.EventBus;
import org.greenrobot.eventbus.Subscribe;
import org.greenrobot.eventbus.ThreadMode;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/AudioPlayerFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/audio/AudioPlayerFragment.java
index 3695e7426..5e1f5c818 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/AudioPlayerFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/audio/AudioPlayerFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment;
+package de.danoeh.antennapod.ui.screen.playback.audio;
import android.content.Intent;
import android.os.Bundle;
@@ -29,6 +29,10 @@ import de.danoeh.antennapod.playback.service.PlaybackController;
import de.danoeh.antennapod.ui.appstartintent.MediaButtonStarter;
import de.danoeh.antennapod.ui.episodes.PlaybackSpeedUtils;
import de.danoeh.antennapod.ui.episodes.TimeSpeedConverter;
+import de.danoeh.antennapod.ui.screen.playback.MediaPlayerErrorDialog;
+import de.danoeh.antennapod.ui.screen.playback.PlayButton;
+import de.danoeh.antennapod.ui.screen.playback.SleepTimerDialog;
+import de.danoeh.antennapod.ui.screen.playback.VariableSpeedDialog;
import org.greenrobot.eventbus.EventBus;
import org.greenrobot.eventbus.Subscribe;
import org.greenrobot.eventbus.ThreadMode;
@@ -41,10 +45,7 @@ import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
import de.danoeh.antennapod.core.util.ChapterUtils;
import de.danoeh.antennapod.ui.common.Converter;
-import de.danoeh.antennapod.dialog.MediaPlayerErrorDialog;
-import de.danoeh.antennapod.dialog.SkipPreferenceDialog;
-import de.danoeh.antennapod.dialog.SleepTimerDialog;
-import de.danoeh.antennapod.dialog.VariableSpeedDialog;
+import de.danoeh.antennapod.ui.screen.feed.preferences.SkipPreferenceDialog;
import de.danoeh.antennapod.event.FavoritesEvent;
import de.danoeh.antennapod.event.PlayerErrorEvent;
import de.danoeh.antennapod.event.UnreadItemsUpdateEvent;
@@ -53,7 +54,7 @@ import de.danoeh.antennapod.event.playback.PlaybackPositionEvent;
import de.danoeh.antennapod.event.playback.PlaybackServiceEvent;
import de.danoeh.antennapod.event.playback.SleepTimerUpdatedEvent;
import de.danoeh.antennapod.event.playback.SpeedChangedEvent;
-import de.danoeh.antennapod.menuhandler.FeedItemMenuHandler;
+import de.danoeh.antennapod.ui.episodeslist.FeedItemMenuHandler;
import de.danoeh.antennapod.model.feed.Chapter;
import de.danoeh.antennapod.model.feed.FeedItem;
import de.danoeh.antennapod.model.feed.FeedMedia;
@@ -61,8 +62,6 @@ import de.danoeh.antennapod.model.playback.Playable;
import de.danoeh.antennapod.playback.cast.CastEnabledActivity;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
import de.danoeh.antennapod.ui.common.PlaybackSpeedIndicatorView;
-import de.danoeh.antennapod.view.ChapterSeekBar;
-import de.danoeh.antennapod.view.PlayButton;
import io.reactivex.Maybe;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.disposables.Disposable;
diff --git a/app/src/main/java/de/danoeh/antennapod/view/ChapterSeekBar.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/audio/ChapterSeekBar.java
index d35206647..0ce284f97 100644
--- a/app/src/main/java/de/danoeh/antennapod/view/ChapterSeekBar.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/audio/ChapterSeekBar.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.view;
+package de.danoeh.antennapod.ui.screen.playback.audio;
import android.content.Context;
import android.graphics.Canvas;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/CoverFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/audio/CoverFragment.java
index 3076b6e63..05e6f3d6c 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/CoverFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/audio/CoverFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment;
+package de.danoeh.antennapod.ui.screen.playback.audio;
import android.animation.Animator;
import android.animation.AnimatorListenerAdapter;
@@ -33,6 +33,7 @@ import com.google.android.material.snackbar.Snackbar;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
import de.danoeh.antennapod.core.util.ChapterUtils;
+import de.danoeh.antennapod.ui.screen.chapter.ChaptersFragment;
import de.danoeh.antennapod.playback.service.PlaybackController;
import de.danoeh.antennapod.ui.common.DateFormatter;
import de.danoeh.antennapod.databinding.CoverFragmentBinding;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/ExternalPlayerFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/audio/ExternalPlayerFragment.java
index 981f8f4b1..67514697f 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/ExternalPlayerFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/audio/ExternalPlayerFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment;
+package de.danoeh.antennapod.ui.screen.playback.audio;
import android.content.Intent;
import android.os.Bundle;
@@ -25,7 +25,7 @@ import de.danoeh.antennapod.playback.base.PlayerStatus;
import de.danoeh.antennapod.playback.service.PlaybackController;
import de.danoeh.antennapod.playback.service.PlaybackService;
import de.danoeh.antennapod.ui.episodes.ImageResourceUtils;
-import de.danoeh.antennapod.view.PlayButton;
+import de.danoeh.antennapod.ui.screen.playback.PlayButton;
import io.reactivex.Maybe;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.disposables.Disposable;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/ItemDescriptionFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/audio/ItemDescriptionFragment.java
index 6ab9dc671..3e7366431 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/ItemDescriptionFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/audio/ItemDescriptionFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment;
+package de.danoeh.antennapod.ui.screen.playback.audio;
import android.app.Activity;
import android.content.Context;
@@ -15,10 +15,10 @@ import androidx.fragment.app.Fragment;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.playback.service.PlaybackController;
import de.danoeh.antennapod.storage.database.DBReader;
-import de.danoeh.antennapod.core.util.gui.ShownotesCleaner;
+import de.danoeh.antennapod.ui.cleaner.ShownotesCleaner;
import de.danoeh.antennapod.model.feed.FeedMedia;
import de.danoeh.antennapod.model.playback.Playable;
-import de.danoeh.antennapod.view.ShownotesWebView;
+import de.danoeh.antennapod.ui.view.ShownotesWebView;
import io.reactivex.Maybe;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.disposables.Disposable;
diff --git a/app/src/main/java/de/danoeh/antennapod/view/NoRelayoutTextView.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/audio/NoRelayoutTextView.java
index cbb2ef0af..86f9a53e9 100644
--- a/app/src/main/java/de/danoeh/antennapod/view/NoRelayoutTextView.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/audio/NoRelayoutTextView.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.view;
+package de.danoeh.antennapod.ui.screen.playback.audio;
import android.content.Context;
import android.util.AttributeSet;
diff --git a/app/src/main/java/de/danoeh/antennapod/view/AspectRatioVideoView.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/video/AspectRatioVideoView.java
index 4c116fa2d..59fa0a07f 100644
--- a/app/src/main/java/de/danoeh/antennapod/view/AspectRatioVideoView.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/video/AspectRatioVideoView.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.view;
+package de.danoeh.antennapod.ui.screen.playback.video;
/*
* Copyright (C) Google Inc. All rights reserved.
diff --git a/core/src/main/java/de/danoeh/antennapod/core/util/gui/PictureInPictureUtil.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/video/PictureInPictureUtil.java
index f763653a1..7f40610cc 100644
--- a/core/src/main/java/de/danoeh/antennapod/core/util/gui/PictureInPictureUtil.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/video/PictureInPictureUtil.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.core.util.gui;
+package de.danoeh.antennapod.ui.screen.playback.video;
import android.app.Activity;
import android.content.pm.PackageManager;
diff --git a/app/src/main/java/de/danoeh/antennapod/activity/VideoplayerActivity.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/video/VideoplayerActivity.java
index 313d97248..2a0746f54 100644
--- a/app/src/main/java/de/danoeh/antennapod/activity/VideoplayerActivity.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/playback/video/VideoplayerActivity.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.activity;
+package de.danoeh.antennapod.ui.screen.playback.video;
import android.content.Intent;
import android.graphics.PixelFormat;
@@ -34,15 +34,14 @@ import androidx.interpolator.view.animation.FastOutSlowInInterpolator;
import com.bumptech.glide.Glide;
import com.google.android.material.dialog.MaterialAlertDialogBuilder;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.dialog.MediaPlayerErrorDialog;
-import de.danoeh.antennapod.dialog.VariableSpeedDialog;
+import de.danoeh.antennapod.activity.MainActivity;
import de.danoeh.antennapod.event.MessageEvent;
import de.danoeh.antennapod.event.playback.BufferUpdateEvent;
import de.danoeh.antennapod.event.playback.PlaybackPositionEvent;
import de.danoeh.antennapod.event.PlayerErrorEvent;
import de.danoeh.antennapod.event.playback.PlaybackServiceEvent;
import de.danoeh.antennapod.event.playback.SleepTimerUpdatedEvent;
-import de.danoeh.antennapod.fragment.ChaptersFragment;
+import de.danoeh.antennapod.ui.screen.chapter.ChaptersFragment;
import de.danoeh.antennapod.playback.service.PlaybackController;
import de.danoeh.antennapod.playback.service.PlaybackService;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
@@ -51,13 +50,10 @@ import de.danoeh.antennapod.storage.database.DBWriter;
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;
-import de.danoeh.antennapod.core.util.gui.PictureInPictureUtil;
+import de.danoeh.antennapod.ui.share.ShareUtils;
import de.danoeh.antennapod.databinding.VideoplayerActivityBinding;
-import de.danoeh.antennapod.dialog.PlaybackControlsDialog;
-import de.danoeh.antennapod.dialog.ShareDialog;
-import de.danoeh.antennapod.dialog.SkipPreferenceDialog;
-import de.danoeh.antennapod.dialog.SleepTimerDialog;
+import de.danoeh.antennapod.ui.share.ShareDialog;
+import de.danoeh.antennapod.ui.screen.feed.preferences.SkipPreferenceDialog;
import de.danoeh.antennapod.model.feed.FeedItem;
import de.danoeh.antennapod.model.feed.FeedMedia;
import de.danoeh.antennapod.model.playback.Playable;
@@ -65,6 +61,10 @@ import de.danoeh.antennapod.playback.base.PlayerStatus;
import de.danoeh.antennapod.playback.cast.CastEnabledActivity;
import de.danoeh.antennapod.ui.appstartintent.MainActivityStarter;
import de.danoeh.antennapod.ui.episodes.TimeSpeedConverter;
+import de.danoeh.antennapod.ui.screen.playback.MediaPlayerErrorDialog;
+import de.danoeh.antennapod.ui.screen.playback.PlaybackControlsDialog;
+import de.danoeh.antennapod.ui.screen.playback.SleepTimerDialog;
+import de.danoeh.antennapod.ui.screen.playback.VariableSpeedDialog;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.disposables.Disposable;
diff --git a/app/src/main/java/de/danoeh/antennapod/activity/BugReportActivity.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/BugReportActivity.java
index e379b5eb2..b4a5218ee 100644
--- a/app/src/main/java/de/danoeh/antennapod/activity/BugReportActivity.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/BugReportActivity.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.activity;
+package de.danoeh.antennapod.ui.screen.preferences;
import android.content.ClipData;
import android.content.ClipboardManager;
@@ -22,7 +22,7 @@ import android.widget.TextView;
import de.danoeh.antennapod.ui.common.ThemeSwitcher;
-import de.danoeh.antennapod.error.CrashReportWriter;
+import de.danoeh.antennapod.CrashReportWriter;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
import de.danoeh.antennapod.core.util.IntentUtils;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/preferences/DownloadsPreferencesFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/DownloadsPreferencesFragment.java
index 58e968155..fad8c6986 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/preferences/DownloadsPreferencesFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/DownloadsPreferencesFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment.preferences;
+package de.danoeh.antennapod.ui.screen.preferences;
import android.content.SharedPreferences;
import android.os.Bundle;
@@ -9,10 +9,8 @@ import androidx.preference.TwoStatePreference;
import com.google.android.material.dialog.MaterialAlertDialogBuilder;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.activity.PreferenceActivity;
import de.danoeh.antennapod.net.download.serviceinterface.FeedUpdateManager;
import de.danoeh.antennapod.ui.preferences.screen.downloads.ChooseDataFolderDialog;
-import de.danoeh.antennapod.dialog.ProxyDialog;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
import java.io.File;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/preferences/ImportExportPreferencesFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/ImportExportPreferencesFragment.java
index 7c607c242..5ffa7e57a 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/preferences/ImportExportPreferencesFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/ImportExportPreferencesFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment.preferences;
+package de.danoeh.antennapod.ui.screen.preferences;
import android.app.Activity;
import android.app.ProgressDialog;
@@ -27,7 +27,6 @@ import androidx.preference.PreferenceFragmentCompat;
import com.google.android.material.snackbar.Snackbar;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.OpmlImportActivity;
-import de.danoeh.antennapod.activity.PreferenceActivity;
import de.danoeh.antennapod.storage.database.DBReader;
import de.danoeh.antennapod.model.feed.FeedItem;
import de.danoeh.antennapod.model.feed.FeedItemFilter;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/preferences/MainPreferencesFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/MainPreferencesFragment.java
index 50d201f39..40a9dd605 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/preferences/MainPreferencesFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/MainPreferencesFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment.preferences;
+package de.danoeh.antennapod.ui.screen.preferences;
import android.content.Intent;
import android.graphics.PorterDuff;
@@ -13,8 +13,6 @@ import com.bytehamster.lib.preferencesearch.SearchConfiguration;
import com.bytehamster.lib.preferencesearch.SearchPreference;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.activity.BugReportActivity;
-import de.danoeh.antennapod.activity.PreferenceActivity;
import de.danoeh.antennapod.core.util.IntentUtils;
import de.danoeh.antennapod.ui.preferences.screen.about.AboutFragment;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/preferences/PlaybackPreferencesFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/PlaybackPreferencesFragment.java
index dcbd96d5b..70d2828bb 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/preferences/PlaybackPreferencesFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/PlaybackPreferencesFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment.preferences;
+package de.danoeh.antennapod.ui.screen.preferences;
import android.app.Activity;
import android.content.res.Resources;
@@ -10,12 +10,11 @@ import androidx.preference.ListPreference;
import androidx.preference.Preference;
import androidx.preference.PreferenceFragmentCompat;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.activity.PreferenceActivity;
import de.danoeh.antennapod.event.UnreadItemsUpdateEvent;
import de.danoeh.antennapod.storage.preferences.UsageStatistics;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
-import de.danoeh.antennapod.dialog.SkipPreferenceDialog;
-import de.danoeh.antennapod.dialog.VariableSpeedDialog;
+import de.danoeh.antennapod.ui.screen.feed.preferences.SkipPreferenceDialog;
+import de.danoeh.antennapod.ui.screen.playback.VariableSpeedDialog;
import java.util.Map;
import org.greenrobot.eventbus.EventBus;
diff --git a/app/src/main/java/de/danoeh/antennapod/activity/PreferenceActivity.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/PreferenceActivity.java
index aa3b05715..e82c2c084 100644
--- a/app/src/main/java/de/danoeh/antennapod/activity/PreferenceActivity.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/PreferenceActivity.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.activity;
+package de.danoeh.antennapod.ui.screen.preferences;
import android.content.Intent;
import android.os.Build;
@@ -23,12 +23,6 @@ import de.danoeh.antennapod.R;
import de.danoeh.antennapod.ui.common.ThemeSwitcher;
import de.danoeh.antennapod.event.MessageEvent;
-import de.danoeh.antennapod.fragment.preferences.ImportExportPreferencesFragment;
-import de.danoeh.antennapod.fragment.preferences.MainPreferencesFragment;
-import de.danoeh.antennapod.fragment.preferences.DownloadsPreferencesFragment;
-import de.danoeh.antennapod.fragment.preferences.PlaybackPreferencesFragment;
-import de.danoeh.antennapod.fragment.preferences.SwipePreferencesFragment;
-import de.danoeh.antennapod.fragment.preferences.UserInterfacePreferencesFragment;
import de.danoeh.antennapod.ui.preferences.screen.AutoDownloadPreferencesFragment;
import de.danoeh.antennapod.ui.preferences.screen.NotificationPreferencesFragment;
import de.danoeh.antennapod.ui.preferences.screen.synchronization.SynchronizationPreferencesFragment;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/preferences/dialog/PreferenceListDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/PreferenceListDialog.java
index b6a11c001..26ed7eada 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/preferences/dialog/PreferenceListDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/PreferenceListDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment.preferences.dialog;
+package de.danoeh.antennapod.ui.screen.preferences;
import android.content.Context;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/preferences/dialog/PreferenceSwitchDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/PreferenceSwitchDialog.java
index 10fbe6137..217785f90 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/preferences/dialog/PreferenceSwitchDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/PreferenceSwitchDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment.preferences.dialog;
+package de.danoeh.antennapod.ui.screen.preferences;
import android.content.Context;
import android.view.LayoutInflater;
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/ProxyDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/ProxyDialog.java
index 8c7a30bff..ca4b4b5e5 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/ProxyDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/ProxyDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui.screen.preferences;
import android.app.Dialog;
import android.content.Context;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/preferences/SwipePreferencesFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/SwipePreferencesFragment.java
index 5b81ff7a5..7522c2a1b 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/preferences/SwipePreferencesFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/SwipePreferencesFragment.java
@@ -1,16 +1,15 @@
-package de.danoeh.antennapod.fragment.preferences;
+package de.danoeh.antennapod.ui.screen.preferences;
import android.os.Bundle;
import androidx.preference.PreferenceFragmentCompat;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.activity.PreferenceActivity;
-import de.danoeh.antennapod.dialog.SwipeActionsDialog;
-import de.danoeh.antennapod.fragment.AllEpisodesFragment;
-import de.danoeh.antennapod.fragment.CompletedDownloadsFragment;
-import de.danoeh.antennapod.fragment.FeedItemlistFragment;
-import de.danoeh.antennapod.fragment.InboxFragment;
-import de.danoeh.antennapod.fragment.PlaybackHistoryFragment;
-import de.danoeh.antennapod.fragment.QueueFragment;
+import de.danoeh.antennapod.ui.swipeactions.SwipeActionsDialog;
+import de.danoeh.antennapod.ui.screen.AllEpisodesFragment;
+import de.danoeh.antennapod.ui.screen.download.CompletedDownloadsFragment;
+import de.danoeh.antennapod.ui.screen.feed.FeedItemlistFragment;
+import de.danoeh.antennapod.ui.screen.InboxFragment;
+import de.danoeh.antennapod.ui.screen.PlaybackHistoryFragment;
+import de.danoeh.antennapod.ui.screen.queue.QueueFragment;
public class SwipePreferencesFragment extends PreferenceFragmentCompat {
private static final String PREF_SWIPE_QUEUE = "prefSwipeQueue";
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/preferences/UserInterfacePreferencesFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/UserInterfacePreferencesFragment.java
index af48c705d..86840f759 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/preferences/UserInterfacePreferencesFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/preferences/UserInterfacePreferencesFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment.preferences;
+package de.danoeh.antennapod.ui.screen.preferences;
import android.content.Context;
import android.content.DialogInterface;
@@ -15,15 +15,14 @@ import androidx.preference.PreferenceFragmentCompat;
import com.google.android.material.dialog.MaterialAlertDialogBuilder;
import com.google.android.material.snackbar.Snackbar;
+import de.danoeh.antennapod.ui.screen.subscriptions.FeedSortDialog;
import org.greenrobot.eventbus.EventBus;
import java.util.List;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.activity.PreferenceActivity;
-import de.danoeh.antennapod.dialog.DrawerPreferencesDialog;
-import de.danoeh.antennapod.dialog.FeedSortDialog;
-import de.danoeh.antennapod.dialog.SubscriptionsFilterDialog;
+import de.danoeh.antennapod.ui.screen.drawer.DrawerPreferencesDialog;
+import de.danoeh.antennapod.ui.screen.subscriptions.SubscriptionsFilterDialog;
import de.danoeh.antennapod.event.PlayerStatusEvent;
import de.danoeh.antennapod.event.UnreadItemsUpdateEvent;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/QueueFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/queue/QueueFragment.java
index 126d0d748..31fedda1d 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/QueueFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/queue/QueueFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment;
+package de.danoeh.antennapod.ui.screen.queue;
import android.content.Context;
import android.content.DialogInterface;
@@ -28,6 +28,7 @@ import com.google.android.material.dialog.MaterialAlertDialogBuilder;
import com.google.android.material.snackbar.Snackbar;
import com.leinardi.android.speeddial.SpeedDialView;
+import de.danoeh.antennapod.ui.screen.SearchFragment;
import de.danoeh.antennapod.net.download.serviceinterface.FeedUpdateManager;
import de.danoeh.antennapod.ui.episodes.PlaybackSpeedUtils;
import org.greenrobot.eventbus.EventBus;
@@ -38,15 +39,14 @@ import java.util.List;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
-import de.danoeh.antennapod.adapter.EpisodeItemListAdapter;
-import de.danoeh.antennapod.adapter.QueueRecyclerAdapter;
-import de.danoeh.antennapod.core.dialog.ConfirmationDialog;
-import de.danoeh.antennapod.core.menuhandler.MenuItemUtils;
+import de.danoeh.antennapod.ui.episodeslist.EpisodeItemListAdapter;
+import de.danoeh.antennapod.core.util.ConfirmationDialog;
+import de.danoeh.antennapod.ui.MenuItemUtils;
import de.danoeh.antennapod.storage.database.DBReader;
import de.danoeh.antennapod.storage.database.DBWriter;
import de.danoeh.antennapod.ui.common.Converter;
import de.danoeh.antennapod.core.util.FeedItemUtil;
-import de.danoeh.antennapod.dialog.ItemSortDialog;
+import de.danoeh.antennapod.ui.screen.feed.ItemSortDialog;
import de.danoeh.antennapod.event.EpisodeDownloadEvent;
import de.danoeh.antennapod.event.FeedItemEvent;
import de.danoeh.antennapod.event.FeedUpdateRunningEvent;
@@ -54,17 +54,17 @@ import de.danoeh.antennapod.event.PlayerStatusEvent;
import de.danoeh.antennapod.event.QueueEvent;
import de.danoeh.antennapod.event.UnreadItemsUpdateEvent;
import de.danoeh.antennapod.event.playback.PlaybackPositionEvent;
-import de.danoeh.antennapod.fragment.actions.EpisodeMultiSelectActionHandler;
-import de.danoeh.antennapod.fragment.swipeactions.SwipeActions;
-import de.danoeh.antennapod.menuhandler.FeedItemMenuHandler;
+import de.danoeh.antennapod.ui.episodeslist.EpisodeMultiSelectActionHandler;
+import de.danoeh.antennapod.ui.swipeactions.SwipeActions;
+import de.danoeh.antennapod.ui.episodeslist.FeedItemMenuHandler;
import de.danoeh.antennapod.model.feed.FeedItem;
import de.danoeh.antennapod.model.feed.FeedItemFilter;
import de.danoeh.antennapod.model.feed.SortOrder;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
-import de.danoeh.antennapod.view.EmptyViewHandler;
-import de.danoeh.antennapod.view.EpisodeItemListRecyclerView;
-import de.danoeh.antennapod.view.LiftOnScrollListener;
-import de.danoeh.antennapod.view.viewholder.EpisodeItemViewHolder;
+import de.danoeh.antennapod.ui.view.EmptyViewHandler;
+import de.danoeh.antennapod.ui.episodeslist.EpisodeItemListRecyclerView;
+import de.danoeh.antennapod.ui.view.LiftOnScrollListener;
+import de.danoeh.antennapod.ui.episodeslist.EpisodeItemViewHolder;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.disposables.Disposable;
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/QueueRecyclerAdapter.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/queue/QueueRecyclerAdapter.java
index 1f4cfd0cf..371118166 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/QueueRecyclerAdapter.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/queue/QueueRecyclerAdapter.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.adapter;
+package de.danoeh.antennapod.ui.screen.queue;
import android.annotation.SuppressLint;
import android.util.Log;
@@ -9,9 +9,10 @@ import android.view.View;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
+import de.danoeh.antennapod.ui.episodeslist.EpisodeItemListAdapter;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
-import de.danoeh.antennapod.fragment.swipeactions.SwipeActions;
-import de.danoeh.antennapod.view.viewholder.EpisodeItemViewHolder;
+import de.danoeh.antennapod.ui.swipeactions.SwipeActions;
+import de.danoeh.antennapod.ui.episodeslist.EpisodeItemViewHolder;
/**
* List adapter for the queue.
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/rating/RatingDialogFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/rating/RatingDialogFragment.java
index 4e9da8b9a..9adf885b1 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/rating/RatingDialogFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/rating/RatingDialogFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog.rating;
+package de.danoeh.antennapod.ui.screen.rating;
import android.app.Dialog;
import android.content.DialogInterface;
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/rating/RatingDialogManager.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/rating/RatingDialogManager.java
index 53e1c8c72..edba0ec83 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/rating/RatingDialogManager.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/rating/RatingDialogManager.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog.rating;
+package de.danoeh.antennapod.ui.screen.rating;
import android.content.Context;
import android.content.SharedPreferences;
diff --git a/app/src/main/java/de/danoeh/antennapod/menuhandler/FeedMenuHandler.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/FeedMenuHandler.java
index c0448884d..e1e9f2287 100644
--- a/app/src/main/java/de/danoeh/antennapod/menuhandler/FeedMenuHandler.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/FeedMenuHandler.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.menuhandler;
+package de.danoeh.antennapod.ui.screen.subscriptions;
import android.annotation.SuppressLint;
import android.content.Context;
@@ -7,11 +7,11 @@ import android.util.Log;
import androidx.annotation.NonNull;
import androidx.fragment.app.Fragment;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.core.dialog.ConfirmationDialog;
+import de.danoeh.antennapod.core.util.ConfirmationDialog;
import de.danoeh.antennapod.storage.database.DBWriter;
-import de.danoeh.antennapod.dialog.RemoveFeedDialog;
-import de.danoeh.antennapod.dialog.RenameItemDialog;
-import de.danoeh.antennapod.dialog.TagSettingsDialog;
+import de.danoeh.antennapod.ui.screen.feed.RemoveFeedDialog;
+import de.danoeh.antennapod.ui.screen.feed.RenameFeedDialog;
+import de.danoeh.antennapod.ui.screen.feed.preferences.TagSettingsDialog;
import de.danoeh.antennapod.model.feed.Feed;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
@@ -31,7 +31,7 @@ public abstract class FeedMenuHandler {
@NonNull Feed selectedFeed, Runnable callback) {
@NonNull Context context = fragment.requireContext();
if (menuItemId == R.id.rename_folder_item) {
- new RenameItemDialog(fragment.getActivity(), selectedFeed).show();
+ new RenameFeedDialog(fragment.getActivity(), selectedFeed).show();
} else if (menuItemId == R.id.remove_all_inbox_item) {
ConfirmationDialog dialog = new ConfirmationDialog(fragment.getActivity(),
R.string.remove_all_inbox_label, R.string.remove_all_inbox_confirmation_msg) {
@@ -52,7 +52,7 @@ public abstract class FeedMenuHandler {
TagSettingsDialog.newInstance(Collections.singletonList(selectedFeed.getPreferences()))
.show(fragment.getChildFragmentManager(), TagSettingsDialog.TAG);
} else if (menuItemId == R.id.rename_item) {
- new RenameItemDialog(fragment.getActivity(), selectedFeed).show();
+ new RenameFeedDialog(fragment.getActivity(), selectedFeed).show();
} else if (menuItemId == R.id.remove_feed) {
RemoveFeedDialog.show(context, selectedFeed, null);
} else {
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/actions/FeedMultiSelectActionHandler.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/FeedMultiSelectActionHandler.java
index 5a6b4ffa9..f2c89f12f 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/actions/FeedMultiSelectActionHandler.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/FeedMultiSelectActionHandler.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment.actions;
+package de.danoeh.antennapod.ui.screen.subscriptions;
import android.util.Log;
@@ -16,12 +16,12 @@ import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
import de.danoeh.antennapod.storage.database.DBWriter;
import de.danoeh.antennapod.databinding.PlaybackSpeedFeedSettingDialogBinding;
-import de.danoeh.antennapod.dialog.RemoveFeedDialog;
-import de.danoeh.antennapod.dialog.TagSettingsDialog;
+import de.danoeh.antennapod.ui.screen.feed.RemoveFeedDialog;
+import de.danoeh.antennapod.ui.screen.feed.preferences.TagSettingsDialog;
import de.danoeh.antennapod.model.feed.Feed;
import de.danoeh.antennapod.model.feed.FeedPreferences;
-import de.danoeh.antennapod.fragment.preferences.dialog.PreferenceListDialog;
-import de.danoeh.antennapod.fragment.preferences.dialog.PreferenceSwitchDialog;
+import de.danoeh.antennapod.ui.screen.preferences.PreferenceListDialog;
+import de.danoeh.antennapod.ui.screen.preferences.PreferenceSwitchDialog;
public class FeedMultiSelectActionHandler {
private static final String TAG = "FeedSelectHandler";
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/FeedSortDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/FeedSortDialog.java
index daa00b8a3..7e42581ce 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/FeedSortDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/FeedSortDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui.screen.subscriptions;
import android.content.Context;
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/HorizontalFeedListAdapter.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/HorizontalFeedListAdapter.java
index 304bf9f64..e66b447f8 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/HorizontalFeedListAdapter.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/HorizontalFeedListAdapter.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.adapter;
+package de.danoeh.antennapod.ui.screen.subscriptions;
import android.view.View;
import android.view.ViewGroup;
@@ -12,7 +12,7 @@ import com.bumptech.glide.request.RequestOptions;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
import de.danoeh.antennapod.model.feed.Feed;
-import de.danoeh.antennapod.fragment.FeedItemlistFragment;
+import de.danoeh.antennapod.ui.screen.feed.FeedItemlistFragment;
import de.danoeh.antennapod.ui.common.SquareImageView;
import java.lang.ref.WeakReference;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/SubscriptionFragment.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/SubscriptionFragment.java
index dcc78f152..f115db0ff 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/SubscriptionFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/SubscriptionFragment.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment;
+package de.danoeh.antennapod.ui.screen.subscriptions;
import android.content.Context;
import android.content.SharedPreferences;
@@ -22,6 +22,8 @@ import com.google.android.material.appbar.MaterialToolbar;
import com.google.android.material.floatingactionbutton.FloatingActionButton;
import com.leinardi.android.speeddial.SpeedDialView;
+import de.danoeh.antennapod.ui.screen.AddFeedFragment;
+import de.danoeh.antennapod.ui.screen.SearchFragment;
import de.danoeh.antennapod.net.download.serviceinterface.FeedUpdateManager;
import org.greenrobot.eventbus.EventBus;
import org.greenrobot.eventbus.Subscribe;
@@ -33,23 +35,18 @@ import java.util.Locale;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
-import de.danoeh.antennapod.adapter.SubscriptionsRecyclerAdapter;
-import de.danoeh.antennapod.core.menuhandler.MenuItemUtils;
+import de.danoeh.antennapod.ui.MenuItemUtils;
import de.danoeh.antennapod.storage.database.DBReader;
import de.danoeh.antennapod.storage.database.NavDrawerData;
-import de.danoeh.antennapod.dialog.FeedSortDialog;
-import de.danoeh.antennapod.dialog.RenameItemDialog;
-import de.danoeh.antennapod.dialog.SubscriptionsFilterDialog;
+import de.danoeh.antennapod.ui.screen.feed.RenameFeedDialog;
import de.danoeh.antennapod.event.FeedListUpdateEvent;
import de.danoeh.antennapod.event.FeedUpdateRunningEvent;
import de.danoeh.antennapod.event.UnreadItemsUpdateEvent;
-import de.danoeh.antennapod.fragment.actions.FeedMultiSelectActionHandler;
-import de.danoeh.antennapod.menuhandler.FeedMenuHandler;
import de.danoeh.antennapod.model.feed.Feed;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
import de.danoeh.antennapod.ui.statistics.StatisticsFragment;
-import de.danoeh.antennapod.view.EmptyViewHandler;
-import de.danoeh.antennapod.view.LiftOnScrollListener;
+import de.danoeh.antennapod.ui.view.EmptyViewHandler;
+import de.danoeh.antennapod.ui.view.LiftOnScrollListener;
import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.disposables.Disposable;
@@ -323,7 +320,7 @@ public class SubscriptionFragment extends Fragment
}
int itemId = item.getItemId();
if (drawerItem.type == NavDrawerData.DrawerItem.Type.TAG && itemId == R.id.rename_folder_item) {
- new RenameItemDialog(getActivity(), drawerItem).show();
+ new RenameFeedDialog(getActivity(), drawerItem).show();
return true;
}
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/SubscriptionsFilterDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/SubscriptionsFilterDialog.java
index 929e6b1ad..53ced5f11 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/SubscriptionsFilterDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/SubscriptionsFilterDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui.screen.subscriptions;
import android.app.Dialog;
import android.os.Bundle;
@@ -16,7 +16,6 @@ import com.google.android.material.bottomsheet.BottomSheetDialog;
import com.google.android.material.bottomsheet.BottomSheetDialogFragment;
import com.google.android.material.button.MaterialButtonToggleGroup;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.core.feed.SubscriptionsFilterGroup;
import de.danoeh.antennapod.databinding.FilterDialogBinding;
import de.danoeh.antennapod.databinding.FilterDialogRowBinding;
import de.danoeh.antennapod.event.UnreadItemsUpdateEvent;
diff --git a/core/src/main/java/de/danoeh/antennapod/core/feed/SubscriptionsFilterGroup.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/SubscriptionsFilterGroup.java
index cea5d96ef..41dce16f0 100644
--- a/core/src/main/java/de/danoeh/antennapod/core/feed/SubscriptionsFilterGroup.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/SubscriptionsFilterGroup.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.core.feed;
+package de.danoeh.antennapod.ui.screen.subscriptions;
import de.danoeh.antennapod.core.R;
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/SubscriptionsRecyclerAdapter.java b/app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/SubscriptionsRecyclerAdapter.java
index 262c1f906..fecb191b3 100644
--- a/app/src/main/java/de/danoeh/antennapod/adapter/SubscriptionsRecyclerAdapter.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/screen/subscriptions/SubscriptionsRecyclerAdapter.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.adapter;
+package de.danoeh.antennapod.ui.screen.subscriptions;
import android.content.Context;
import android.graphics.Canvas;
@@ -32,10 +32,11 @@ import java.util.List;
import de.danoeh.antennapod.R;
import de.danoeh.antennapod.activity.MainActivity;
+import de.danoeh.antennapod.ui.CoverLoader;
+import de.danoeh.antennapod.ui.SelectableAdapter;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
import de.danoeh.antennapod.storage.database.NavDrawerData;
-import de.danoeh.antennapod.fragment.FeedItemlistFragment;
-import de.danoeh.antennapod.fragment.SubscriptionFragment;
+import de.danoeh.antennapod.ui.screen.feed.FeedItemlistFragment;
import de.danoeh.antennapod.model.feed.Feed;
/**
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/ShareDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/share/ShareDialog.java
index 5fb8a352f..963c0b14b 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/ShareDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/share/ShareDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui.share;
import android.content.Context;
import android.content.SharedPreferences;
@@ -9,7 +9,6 @@ import android.view.ViewGroup;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import com.google.android.material.bottomsheet.BottomSheetDialogFragment;
-import de.danoeh.antennapod.core.util.ShareUtils;
import de.danoeh.antennapod.databinding.ShareEpisodeDialogBinding;
import de.danoeh.antennapod.model.feed.FeedItem;
diff --git a/core/src/main/java/de/danoeh/antennapod/core/util/ShareUtils.java b/app/src/main/java/de/danoeh/antennapod/ui/share/ShareUtils.java
index 316771123..77d5f4305 100644
--- a/core/src/main/java/de/danoeh/antennapod/core/util/ShareUtils.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/share/ShareUtils.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.core.util;
+package de.danoeh.antennapod.ui.share;
import android.content.Context;
import android.content.Intent;
@@ -9,6 +9,7 @@ import androidx.annotation.NonNull;
import androidx.core.app.ShareCompat;
import androidx.core.content.FileProvider;
+import de.danoeh.antennapod.core.util.FeedItemUtil;
import de.danoeh.antennapod.ui.common.Converter;
import java.io.File;
import java.net.URLEncoder;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/AddToQueueSwipeAction.java b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/AddToQueueSwipeAction.java
index 06efda3ee..0870adff9 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/AddToQueueSwipeAction.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/AddToQueueSwipeAction.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment.swipeactions;
+package de.danoeh.antennapod.ui.swipeactions;
import android.content.Context;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/DeleteSwipeAction.java b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/DeleteSwipeAction.java
index 52f214eed..1ecfd11e0 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/DeleteSwipeAction.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/DeleteSwipeAction.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment.swipeactions;
+package de.danoeh.antennapod.ui.swipeactions;
import android.content.Context;
import androidx.fragment.app.Fragment;
@@ -9,7 +9,7 @@ import de.danoeh.antennapod.R;
import de.danoeh.antennapod.storage.database.DBWriter;
import de.danoeh.antennapod.model.feed.FeedItem;
import de.danoeh.antennapod.model.feed.FeedItemFilter;
-import de.danoeh.antennapod.view.LocalDeleteModal;
+import de.danoeh.antennapod.ui.view.LocalDeleteModal;
public class DeleteSwipeAction implements SwipeAction {
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/MarkFavoriteSwipeAction.java b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/MarkFavoriteSwipeAction.java
index dcea8c031..8ce0f8482 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/MarkFavoriteSwipeAction.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/MarkFavoriteSwipeAction.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment.swipeactions;
+package de.danoeh.antennapod.ui.swipeactions;
import android.content.Context;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/RemoveFromHistorySwipeAction.java b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/RemoveFromHistorySwipeAction.java
index 46285734e..e757ece42 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/RemoveFromHistorySwipeAction.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/RemoveFromHistorySwipeAction.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment.swipeactions;
+package de.danoeh.antennapod.ui.swipeactions;
import android.content.Context;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/RemoveFromInboxSwipeAction.java b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/RemoveFromInboxSwipeAction.java
index 41d79a711..c7bebecab 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/RemoveFromInboxSwipeAction.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/RemoveFromInboxSwipeAction.java
@@ -1,11 +1,11 @@
-package de.danoeh.antennapod.fragment.swipeactions;
+package de.danoeh.antennapod.ui.swipeactions;
import android.content.Context;
import androidx.fragment.app.Fragment;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.menuhandler.FeedItemMenuHandler;
+import de.danoeh.antennapod.ui.episodeslist.FeedItemMenuHandler;
import de.danoeh.antennapod.model.feed.FeedItem;
import de.danoeh.antennapod.model.feed.FeedItemFilter;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/RemoveFromQueueSwipeAction.java b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/RemoveFromQueueSwipeAction.java
index f5cbf66c6..dbdc3126b 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/RemoveFromQueueSwipeAction.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/RemoveFromQueueSwipeAction.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment.swipeactions;
+package de.danoeh.antennapod.ui.swipeactions;
import android.content.Context;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/ShowFirstSwipeDialogAction.java b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/ShowFirstSwipeDialogAction.java
index 3a6174e8f..3c0afee81 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/ShowFirstSwipeDialogAction.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/ShowFirstSwipeDialogAction.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment.swipeactions;
+package de.danoeh.antennapod.ui.swipeactions;
import android.content.Context;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/StartDownloadSwipeAction.java b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/StartDownloadSwipeAction.java
index 84dc8f417..0df3bcaec 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/StartDownloadSwipeAction.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/StartDownloadSwipeAction.java
@@ -1,9 +1,9 @@
-package de.danoeh.antennapod.fragment.swipeactions;
+package de.danoeh.antennapod.ui.swipeactions;
import android.content.Context;
import androidx.fragment.app.Fragment;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.adapter.actionbutton.DownloadActionButton;
+import de.danoeh.antennapod.actionbutton.DownloadActionButton;
import de.danoeh.antennapod.model.feed.FeedItem;
import de.danoeh.antennapod.model.feed.FeedItemFilter;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/SwipeAction.java b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/SwipeAction.java
index 4b1cfdc78..007bdeff3 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/SwipeAction.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/SwipeAction.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment.swipeactions;
+package de.danoeh.antennapod.ui.swipeactions;
import android.content.Context;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/SwipeActions.java b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/SwipeActions.java
index 28320099a..fdc22094e 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/SwipeActions.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/SwipeActions.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.fragment.swipeactions;
+package de.danoeh.antennapod.ui.swipeactions;
import android.content.Context;
import android.content.SharedPreferences;
@@ -18,16 +18,15 @@ import java.util.Collections;
import java.util.List;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.dialog.SwipeActionsDialog;
-import de.danoeh.antennapod.fragment.AllEpisodesFragment;
-import de.danoeh.antennapod.fragment.CompletedDownloadsFragment;
-import de.danoeh.antennapod.fragment.InboxFragment;
-import de.danoeh.antennapod.fragment.PlaybackHistoryFragment;
-import de.danoeh.antennapod.fragment.QueueFragment;
+import de.danoeh.antennapod.ui.screen.AllEpisodesFragment;
+import de.danoeh.antennapod.ui.screen.download.CompletedDownloadsFragment;
+import de.danoeh.antennapod.ui.screen.InboxFragment;
+import de.danoeh.antennapod.ui.screen.PlaybackHistoryFragment;
+import de.danoeh.antennapod.ui.screen.queue.QueueFragment;
import de.danoeh.antennapod.model.feed.FeedItem;
import de.danoeh.antennapod.model.feed.FeedItemFilter;
import de.danoeh.antennapod.ui.common.ThemeUtils;
-import de.danoeh.antennapod.view.viewholder.EpisodeItemViewHolder;
+import de.danoeh.antennapod.ui.episodeslist.EpisodeItemViewHolder;
import it.xabaras.android.recyclerview.swipedecorator.RecyclerViewSwipeDecorator;
public class SwipeActions extends ItemTouchHelper.SimpleCallback implements LifecycleObserver {
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/SwipeActionsDialog.java b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/SwipeActionsDialog.java
index 2cd03e21d..a02a685f0 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/SwipeActionsDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/SwipeActionsDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.dialog;
+package de.danoeh.antennapod.ui.swipeactions;
import android.content.Context;
import android.content.SharedPreferences;
@@ -22,22 +22,12 @@ import de.danoeh.antennapod.databinding.SwipeactionsDialogBinding;
import de.danoeh.antennapod.databinding.SwipeactionsPickerBinding;
import de.danoeh.antennapod.databinding.SwipeactionsPickerItemBinding;
import de.danoeh.antennapod.databinding.SwipeactionsRowBinding;
-import de.danoeh.antennapod.fragment.AllEpisodesFragment;
-import de.danoeh.antennapod.fragment.CompletedDownloadsFragment;
-import de.danoeh.antennapod.fragment.FeedItemlistFragment;
-import de.danoeh.antennapod.fragment.InboxFragment;
-import de.danoeh.antennapod.fragment.PlaybackHistoryFragment;
-import de.danoeh.antennapod.fragment.QueueFragment;
-import de.danoeh.antennapod.fragment.swipeactions.AddToQueueSwipeAction;
-import de.danoeh.antennapod.fragment.swipeactions.DeleteSwipeAction;
-import de.danoeh.antennapod.fragment.swipeactions.MarkFavoriteSwipeAction;
-import de.danoeh.antennapod.fragment.swipeactions.RemoveFromHistorySwipeAction;
-import de.danoeh.antennapod.fragment.swipeactions.RemoveFromInboxSwipeAction;
-import de.danoeh.antennapod.fragment.swipeactions.RemoveFromQueueSwipeAction;
-import de.danoeh.antennapod.fragment.swipeactions.StartDownloadSwipeAction;
-import de.danoeh.antennapod.fragment.swipeactions.SwipeAction;
-import de.danoeh.antennapod.fragment.swipeactions.SwipeActions;
-import de.danoeh.antennapod.fragment.swipeactions.TogglePlaybackStateSwipeAction;
+import de.danoeh.antennapod.ui.screen.AllEpisodesFragment;
+import de.danoeh.antennapod.ui.screen.download.CompletedDownloadsFragment;
+import de.danoeh.antennapod.ui.screen.feed.FeedItemlistFragment;
+import de.danoeh.antennapod.ui.screen.InboxFragment;
+import de.danoeh.antennapod.ui.screen.PlaybackHistoryFragment;
+import de.danoeh.antennapod.ui.screen.queue.QueueFragment;
import de.danoeh.antennapod.ui.common.ThemeUtils;
public class SwipeActionsDialog {
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/TogglePlaybackStateSwipeAction.java b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/TogglePlaybackStateSwipeAction.java
index 8d4133058..aa83d5e3e 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/swipeactions/TogglePlaybackStateSwipeAction.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/swipeactions/TogglePlaybackStateSwipeAction.java
@@ -1,11 +1,11 @@
-package de.danoeh.antennapod.fragment.swipeactions;
+package de.danoeh.antennapod.ui.swipeactions;
import android.content.Context;
import androidx.fragment.app.Fragment;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.menuhandler.FeedItemMenuHandler;
+import de.danoeh.antennapod.ui.episodeslist.FeedItemMenuHandler;
import de.danoeh.antennapod.model.feed.FeedItem;
import de.danoeh.antennapod.model.feed.FeedItemFilter;
diff --git a/app/src/main/java/de/danoeh/antennapod/view/EmptyViewHandler.java b/app/src/main/java/de/danoeh/antennapod/ui/view/EmptyViewHandler.java
index 2ecaaa5b3..b467f6f0e 100644
--- a/app/src/main/java/de/danoeh/antennapod/view/EmptyViewHandler.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/view/EmptyViewHandler.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.view;
+package de.danoeh.antennapod.ui.view;
import android.content.Context;
import android.database.DataSetObserver;
diff --git a/app/src/main/java/de/danoeh/antennapod/view/ItemOffsetDecoration.java b/app/src/main/java/de/danoeh/antennapod/ui/view/ItemOffsetDecoration.java
index 4a1267d81..4c3adcbc1 100644
--- a/app/src/main/java/de/danoeh/antennapod/view/ItemOffsetDecoration.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/view/ItemOffsetDecoration.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.view;
+package de.danoeh.antennapod.ui.view;
import android.content.Context;
import android.graphics.Rect;
diff --git a/app/src/main/java/de/danoeh/antennapod/view/LiftOnScrollListener.java b/app/src/main/java/de/danoeh/antennapod/ui/view/LiftOnScrollListener.java
index 020fb40e8..e046dd43e 100644
--- a/app/src/main/java/de/danoeh/antennapod/view/LiftOnScrollListener.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/view/LiftOnScrollListener.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.view;
+package de.danoeh.antennapod.ui.view;
import android.animation.ValueAnimator;
import android.view.View;
diff --git a/app/src/main/java/de/danoeh/antennapod/view/LocalDeleteModal.java b/app/src/main/java/de/danoeh/antennapod/ui/view/LocalDeleteModal.java
index a3f541e06..f0a1105c1 100644
--- a/app/src/main/java/de/danoeh/antennapod/view/LocalDeleteModal.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/view/LocalDeleteModal.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.view;
+package de.danoeh.antennapod.ui.view;
import android.content.Context;
diff --git a/app/src/main/java/de/danoeh/antennapod/view/LockableBottomSheetBehavior.java b/app/src/main/java/de/danoeh/antennapod/ui/view/LockableBottomSheetBehavior.java
index 1b96c7c4f..aa506aaea 100644
--- a/app/src/main/java/de/danoeh/antennapod/view/LockableBottomSheetBehavior.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/view/LockableBottomSheetBehavior.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.view;
+package de.danoeh.antennapod.ui.view;
import android.content.Context;
import android.util.AttributeSet;
diff --git a/app/src/main/java/de/danoeh/antennapod/view/NestedScrollableHost.java b/app/src/main/java/de/danoeh/antennapod/ui/view/NestedScrollableHost.java
index 660aa1ea9..b29792d90 100644
--- a/app/src/main/java/de/danoeh/antennapod/view/NestedScrollableHost.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/view/NestedScrollableHost.java
@@ -17,7 +17,7 @@
* And modified for our need
*/
-package de.danoeh.antennapod.view;
+package de.danoeh.antennapod.ui.view;
import android.content.Context;
import android.content.res.TypedArray;
diff --git a/app/src/main/java/de/danoeh/antennapod/view/ShownotesWebView.java b/app/src/main/java/de/danoeh/antennapod/ui/view/ShownotesWebView.java
index f470b0aac..67a659418 100644
--- a/app/src/main/java/de/danoeh/antennapod/view/ShownotesWebView.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/view/ShownotesWebView.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.view;
+package de.danoeh.antennapod.ui.view;
import android.content.ClipData;
import android.content.ClipboardManager;
@@ -24,12 +24,12 @@ 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.ui.MenuItemUtils;
import de.danoeh.antennapod.ui.common.Converter;
import de.danoeh.antennapod.core.util.IntentUtils;
import de.danoeh.antennapod.net.common.NetworkUtils;
-import de.danoeh.antennapod.core.util.ShareUtils;
-import de.danoeh.antennapod.core.util.gui.ShownotesCleaner;
+import de.danoeh.antennapod.ui.share.ShareUtils;
+import de.danoeh.antennapod.ui.cleaner.ShownotesCleaner;
public class ShownotesWebView extends WebView implements View.OnLongClickListener {
private static final String TAG = "ShownotesWebView";
diff --git a/app/src/main/java/de/danoeh/antennapod/view/SimpleAdapterDataObserver.java b/app/src/main/java/de/danoeh/antennapod/ui/view/SimpleAdapterDataObserver.java
index 5bd335532..2e00aa436 100644
--- a/app/src/main/java/de/danoeh/antennapod/view/SimpleAdapterDataObserver.java
+++ b/app/src/main/java/de/danoeh/antennapod/ui/view/SimpleAdapterDataObserver.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.view;
+package de.danoeh.antennapod.ui.view;
import androidx.annotation.Nullable;
import androidx.recyclerview.widget.RecyclerView;
diff --git a/app/src/main/res/layout-sw720dp/main.xml b/app/src/main/res/layout-sw720dp/main.xml
index d2b231992..e8edc260f 100644
--- a/app/src/main/res/layout-sw720dp/main.xml
+++ b/app/src/main/res/layout-sw720dp/main.xml
@@ -40,7 +40,7 @@
android:background="?android:attr/colorBackground"
android:elevation="8dp"
android:visibility="gone"
- app:layout_behavior="de.danoeh.antennapod.view.LockableBottomSheetBehavior" />
+ app:layout_behavior="de.danoeh.antennapod.ui.view.LockableBottomSheetBehavior" />
</androidx.coordinatorlayout.widget.CoordinatorLayout>
diff --git a/app/src/main/res/layout/audioplayer_fragment.xml b/app/src/main/res/layout/audioplayer_fragment.xml
index 1a6794db9..5f4775141 100644
--- a/app/src/main/res/layout/audioplayer_fragment.xml
+++ b/app/src/main/res/layout/audioplayer_fragment.xml
@@ -86,7 +86,7 @@
android:layoutDirection="ltr"
android:orientation="vertical">
- <de.danoeh.antennapod.view.ChapterSeekBar
+ <de.danoeh.antennapod.ui.screen.playback.audio.ChapterSeekBar
android:id="@+id/sbPosition"
android:layout_width="match_parent"
android:layout_height="wrap_content"
@@ -104,7 +104,7 @@
android:paddingLeft="8dp"
android:paddingRight="8dp">
- <de.danoeh.antennapod.view.NoRelayoutTextView
+ <de.danoeh.antennapod.ui.screen.playback.audio.NoRelayoutTextView
android:id="@+id/txtvPosition"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
@@ -116,7 +116,7 @@
android:textColor="?android:attr/textColorSecondary"
android:textSize="@dimen/text_size_micro" />
- <de.danoeh.antennapod.view.NoRelayoutTextView
+ <de.danoeh.antennapod.ui.screen.playback.audio.NoRelayoutTextView
android:id="@+id/txtvLength"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
@@ -138,7 +138,7 @@
android:layout_height="wrap_content"
android:layout_marginBottom="24dp">
- <de.danoeh.antennapod.view.PlayButton
+ <de.danoeh.antennapod.ui.screen.playback.PlayButton
android:id="@+id/butPlay"
android:layout_width="@dimen/audioplayer_playercontrols_length_big"
android:layout_height="@dimen/audioplayer_playercontrols_length_big"
diff --git a/app/src/main/res/layout/episodes_list_fragment.xml b/app/src/main/res/layout/episodes_list_fragment.xml
index 19b21f4f6..d408f531c 100644
--- a/app/src/main/res/layout/episodes_list_fragment.xml
+++ b/app/src/main/res/layout/episodes_list_fragment.xml
@@ -40,7 +40,7 @@
android:layout_height="match_parent"
android:layout_below="@id/appbar">
- <de.danoeh.antennapod.view.EpisodeItemListRecyclerView
+ <de.danoeh.antennapod.ui.episodeslist.EpisodeItemListRecyclerView
android:id="@+id/recyclerView"
android:layout_width="match_parent"
android:layout_height="match_parent"
diff --git a/app/src/main/res/layout/external_player_fragment.xml b/app/src/main/res/layout/external_player_fragment.xml
index 4012595bc..233d06077 100644
--- a/app/src/main/res/layout/external_player_fragment.xml
+++ b/app/src/main/res/layout/external_player_fragment.xml
@@ -55,7 +55,7 @@
</LinearLayout>
- <de.danoeh.antennapod.view.PlayButton
+ <de.danoeh.antennapod.ui.screen.playback.PlayButton
android:id="@+id/butPlay"
android:layout_width="52dp"
android:layout_height="match_parent"
diff --git a/app/src/main/res/layout/feed_item_list_fragment.xml b/app/src/main/res/layout/feed_item_list_fragment.xml
index 1072924d5..23cbe0f05 100644
--- a/app/src/main/res/layout/feed_item_list_fragment.xml
+++ b/app/src/main/res/layout/feed_item_list_fragment.xml
@@ -52,7 +52,7 @@
android:layout_height="match_parent"
app:layout_behavior="@string/appbar_scrolling_view_behavior">
- <de.danoeh.antennapod.view.EpisodeItemListRecyclerView
+ <de.danoeh.antennapod.ui.episodeslist.EpisodeItemListRecyclerView
android:id="@+id/recyclerView"
android:layout_width="match_parent"
android:layout_height="match_parent"
diff --git a/app/src/main/res/layout/feeditem_fragment.xml b/app/src/main/res/layout/feeditem_fragment.xml
index 0e5ace85f..37db9067c 100644
--- a/app/src/main/res/layout/feeditem_fragment.xml
+++ b/app/src/main/res/layout/feeditem_fragment.xml
@@ -190,19 +190,19 @@
</LinearLayout>
- <de.danoeh.antennapod.view.NestedScrollableHost
+ <de.danoeh.antennapod.ui.view.NestedScrollableHost
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_below="@id/header"
app:preferVertical="3">
- <de.danoeh.antennapod.view.ShownotesWebView
+ <de.danoeh.antennapod.ui.view.ShownotesWebView
android:id="@+id/webvDescription"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:foreground="?android:windowContentOverlay" />
- </de.danoeh.antennapod.view.NestedScrollableHost>
+ </de.danoeh.antennapod.ui.view.NestedScrollableHost>
<FrameLayout
android:layout_width="match_parent"
diff --git a/app/src/main/res/layout/item_description_fragment.xml b/app/src/main/res/layout/item_description_fragment.xml
index 469cd4098..13c31b68f 100644
--- a/app/src/main/res/layout/item_description_fragment.xml
+++ b/app/src/main/res/layout/item_description_fragment.xml
@@ -1,15 +1,16 @@
<?xml version="1.0" encoding="utf-8"?>
-<de.danoeh.antennapod.view.NestedScrollableHost xmlns:android="http://schemas.android.com/apk/res/android"
+<de.danoeh.antennapod.ui.view.NestedScrollableHost
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent"
- xmlns:app="http://schemas.android.com/apk/res-auto"
android:fillViewport="false"
- app:preferVertical="10"
- android:nestedScrollingEnabled="true">
+ android:nestedScrollingEnabled="true"
+ app:preferVertical="10">
- <de.danoeh.antennapod.view.ShownotesWebView
+ <de.danoeh.antennapod.ui.view.ShownotesWebView
android:id="@+id/webview"
android:layout_width="match_parent"
- android:layout_height="match_parent"/>
+ android:layout_height="match_parent" />
-</de.danoeh.antennapod.view.NestedScrollableHost> \ No newline at end of file
+</de.danoeh.antennapod.ui.view.NestedScrollableHost>
diff --git a/app/src/main/res/layout/main.xml b/app/src/main/res/layout/main.xml
index 3a368e90e..e205707d5 100644
--- a/app/src/main/res/layout/main.xml
+++ b/app/src/main/res/layout/main.xml
@@ -32,7 +32,7 @@
android:background="?android:attr/colorBackground"
android:elevation="8dp"
android:visibility="gone"
- app:layout_behavior="de.danoeh.antennapod.view.LockableBottomSheetBehavior" />
+ app:layout_behavior="de.danoeh.antennapod.ui.view.LockableBottomSheetBehavior" />
</androidx.coordinatorlayout.widget.CoordinatorLayout>
diff --git a/app/src/main/res/layout/playback_speed_feed_setting_dialog.xml b/app/src/main/res/layout/playback_speed_feed_setting_dialog.xml
index 50eb4f84f..317f86093 100644
--- a/app/src/main/res/layout/playback_speed_feed_setting_dialog.xml
+++ b/app/src/main/res/layout/playback_speed_feed_setting_dialog.xml
@@ -19,7 +19,7 @@
android:orientation="horizontal"
android:gravity="center_vertical">
- <de.danoeh.antennapod.view.PlaybackSpeedSeekBar
+ <de.danoeh.antennapod.ui.screen.playback.PlaybackSpeedSeekBar
android:id="@+id/seekBar"
android:layout_width="0dp"
android:layout_height="wrap_content"
diff --git a/app/src/main/res/layout/queue_fragment.xml b/app/src/main/res/layout/queue_fragment.xml
index 50a0337fb..801c9e93a 100644
--- a/app/src/main/res/layout/queue_fragment.xml
+++ b/app/src/main/res/layout/queue_fragment.xml
@@ -41,7 +41,7 @@
android:layout_height="match_parent"
android:layout_below="@id/appbar">
- <de.danoeh.antennapod.view.EpisodeItemListRecyclerView
+ <de.danoeh.antennapod.ui.episodeslist.EpisodeItemListRecyclerView
android:id="@+id/recyclerView"
android:layout_width="match_parent"
android:layout_height="match_parent"
diff --git a/app/src/main/res/layout/search_fragment.xml b/app/src/main/res/layout/search_fragment.xml
index 17f679cc3..59853a9ee 100644
--- a/app/src/main/res/layout/search_fragment.xml
+++ b/app/src/main/res/layout/search_fragment.xml
@@ -52,7 +52,7 @@
android:paddingRight="12dp"
android:clipToPadding="false" />
- <de.danoeh.antennapod.view.EpisodeItemListRecyclerView
+ <de.danoeh.antennapod.ui.episodeslist.EpisodeItemListRecyclerView
android:id="@+id/recyclerView"
android:layout_width="match_parent"
android:layout_height="match_parent"
diff --git a/app/src/main/res/layout/simple_list_fragment.xml b/app/src/main/res/layout/simple_list_fragment.xml
index bcc43cfcc..273a08846 100644
--- a/app/src/main/res/layout/simple_list_fragment.xml
+++ b/app/src/main/res/layout/simple_list_fragment.xml
@@ -20,7 +20,7 @@
</com.google.android.material.appbar.AppBarLayout>
- <de.danoeh.antennapod.view.EpisodeItemListRecyclerView
+ <de.danoeh.antennapod.ui.episodeslist.EpisodeItemListRecyclerView
android:id="@+id/recyclerView"
android:layout_width="match_parent"
android:layout_height="match_parent"
diff --git a/app/src/main/res/layout/speed_select_dialog.xml b/app/src/main/res/layout/speed_select_dialog.xml
index 0b9e422a8..ad8e1ddcd 100644
--- a/app/src/main/res/layout/speed_select_dialog.xml
+++ b/app/src/main/res/layout/speed_select_dialog.xml
@@ -24,7 +24,7 @@
</LinearLayout>
- <de.danoeh.antennapod.view.PlaybackSpeedSeekBar
+ <de.danoeh.antennapod.ui.screen.playback.PlaybackSpeedSeekBar
android:id="@+id/speed_seek_bar"
android:layout_width="match_parent"
android:layout_height="wrap_content"
diff --git a/app/src/main/res/layout/videoplayer_activity.xml b/app/src/main/res/layout/videoplayer_activity.xml
index fcc1c5f15..d677b930b 100644
--- a/app/src/main/res/layout/videoplayer_activity.xml
+++ b/app/src/main/res/layout/videoplayer_activity.xml
@@ -1,14 +1,15 @@
<?xml version="1.0" encoding="utf-8"?>
-<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
+<FrameLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
+ xmlns:tools="http://schemas.android.com/tools"
+ android:id="@+id/videoPlayerContainer"
android:layout_width="match_parent"
android:layout_height="match_parent"
- xmlns:tools="http://schemas.android.com/tools"
android:background="@color/black"
- android:orientation="vertical"
- android:id="@+id/videoPlayerContainer">
+ android:orientation="vertical">
- <de.danoeh.antennapod.view.AspectRatioVideoView
+ <de.danoeh.antennapod.ui.screen.playback.video.AspectRatioVideoView
android:id="@+id/videoView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
@@ -41,7 +42,7 @@
android:contentDescription="@string/rewind_label"
app:srcCompat="@drawable/ic_fast_rewind_video_white" />
- <de.danoeh.antennapod.view.PlayButton
+ <de.danoeh.antennapod.ui.screen.playback.PlayButton
android:id="@+id/playButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
@@ -67,7 +68,7 @@
android:layout_height="wrap_content"
android:visibility="gone"
android:padding="64dp"
- android:layout_gravity="center"/>
+ android:layout_gravity="center" />
<LinearLayout
android:id="@+id/bottomControlsContainer"
@@ -78,9 +79,9 @@
<androidx.cardview.widget.CardView
android:id="@+id/seekCardView"
- android:alpha="0"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
+ android:alpha="0"
android:layout_marginBottom="12dp"
android:layout_gravity="center"
app:cardCornerRadius="8dp"
@@ -90,9 +91,9 @@
<TextView
android:id="@+id/seekPositionLabel"
- android:gravity="center"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
+ android:gravity="center"
android:paddingLeft="24dp"
android:paddingTop="4dp"
android:paddingRight="24dp"
diff --git a/app/src/main/res/xml/feed_settings.xml b/app/src/main/res/xml/feed_settings.xml
index 2662b1906..11e7132a5 100644
--- a/app/src/main/res/xml/feed_settings.xml
+++ b/app/src/main/res/xml/feed_settings.xml
@@ -48,7 +48,7 @@
android:summary="@string/global_default"
android:title="@string/auto_delete_label" />
- <de.danoeh.antennapod.preferences.VolumeAdaptationPreference
+ <de.danoeh.antennapod.ui.screen.feed.preferences.VolumeAdaptationPreference
android:defaultValue="off"
android:entries="@array/spnVolumeAdaptationItems"
android:entryValues="@array/spnVolumeAdaptationValues"
diff --git a/core/src/test/java/de/danoeh/antennapod/core/util/gui/ShownotesCleanerTest.java b/app/src/test/java/de/danoeh/antennapod/ui/cleaner/ShownotesCleanerTest.java
index 527d0e0a3..cf7d9db34 100644
--- a/core/src/test/java/de/danoeh/antennapod/core/util/gui/ShownotesCleanerTest.java
+++ b/app/src/test/java/de/danoeh/antennapod/ui/cleaner/ShownotesCleanerTest.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.core.util.gui;
+package de.danoeh.antennapod.ui.cleaner;
import android.content.Context;
diff --git a/core/src/test/java/de/danoeh/antennapod/core/util/syndication/FeedDiscovererTest.java b/app/src/test/java/de/danoeh/antennapod/ui/screen/onlinefeedview/FeedDiscovererTest.java
index 3df5230cc..ee9f8a6d5 100644
--- a/core/src/test/java/de/danoeh/antennapod/core/util/syndication/FeedDiscovererTest.java
+++ b/app/src/test/java/de/danoeh/antennapod/ui/screen/onlinefeedview/FeedDiscovererTest.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.core.util.syndication;
+package de.danoeh.antennapod.ui.screen.onlinefeedview;
import androidx.test.platform.app.InstrumentationRegistry;
diff --git a/config/spotbugs/exclude.xml b/config/spotbugs/exclude.xml
index 5eedd1775..35f0881b7 100644
--- a/config/spotbugs/exclude.xml
+++ b/config/spotbugs/exclude.xml
@@ -2,7 +2,7 @@
<FindBugsFilter>
<Match>
<Bug pattern="BC_UNCONFIRMED_CAST"/>
- <Class name="de.danoeh.antennapod.adapter.NavListAdapter"/>
+ <Class name="de.danoeh.antennapod.ui.screen.drawer.NavListAdapter"/>
</Match>
<Match>
<Bug pattern="DLS_DEAD_LOCAL_STORE"/>
@@ -34,7 +34,7 @@
</Match>
<Match>
<Bug pattern="MS_MUTABLE_ARRAY"/>
- <Class name="de.danoeh.antennapod.fragment.NavDrawerFragment"/>
+ <Class name="de.danoeh.antennapod.ui.screen.drawer.NavDrawerFragment"/>
</Match>
<Match>
<Bug pattern="MS_SHOULD_BE_FINAL"/>
@@ -58,7 +58,7 @@
</Match>
<Match>
<Bug pattern="RV_RETURN_VALUE_IGNORED_BAD_PRACTICE"/>
- <Class name="de.danoeh.antennapod.preferences.PreferenceUpgrader"/>
+ <Class name="de.danoeh.antennapod.PreferenceUpgrader"/>
</Match>
<Match>
<Bug pattern="ST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD"/>
diff --git a/core/src/main/java/de/danoeh/antennapod/core/storage/AutomaticDownloadAlgorithm.java b/core/src/main/java/de/danoeh/antennapod/core/storage/AutomaticDownloadAlgorithm.java
index 93f7d578a..dbcc899ba 100644
--- a/core/src/main/java/de/danoeh/antennapod/core/storage/AutomaticDownloadAlgorithm.java
+++ b/core/src/main/java/de/danoeh/antennapod/core/storage/AutomaticDownloadAlgorithm.java
@@ -1,6 +1,9 @@
package de.danoeh.antennapod.core.storage;
import android.content.Context;
+import android.content.Intent;
+import android.content.IntentFilter;
+import android.os.BatteryManager;
import android.util.Log;
import java.util.ArrayList;
@@ -15,7 +18,6 @@ import de.danoeh.antennapod.net.download.serviceinterface.DownloadServiceInterfa
import de.danoeh.antennapod.storage.database.DBReader;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
import de.danoeh.antennapod.net.common.NetworkUtils;
-import de.danoeh.antennapod.core.util.PowerUtils;
/**
* Implements the automatic download algorithm used by AntennaPod. This class assumes that
@@ -42,8 +44,7 @@ public class AutomaticDownloadAlgorithm {
&& UserPreferences.isEnableAutodownload();
// true if we should auto download based on power status
- boolean powerShouldAutoDl = PowerUtils.deviceCharging(context)
- || UserPreferences.isEnableAutodownloadOnBattery();
+ boolean powerShouldAutoDl = deviceCharging(context) || UserPreferences.isEnableAutodownloadOnBattery();
// we should only auto download if both network AND power are happy
if (networkShouldAutoDl && powerShouldAutoDl) {
@@ -103,4 +104,18 @@ public class AutomaticDownloadAlgorithm {
}
};
}
+
+ /**
+ * @return true if the device is charging
+ */
+ public static boolean deviceCharging(Context context) {
+ // from http://developer.android.com/training/monitoring-device-state/battery-monitoring.html
+ IntentFilter intentFilter = new IntentFilter(Intent.ACTION_BATTERY_CHANGED);
+ Intent batteryStatus = context.registerReceiver(null, intentFilter);
+
+ int status = batteryStatus.getIntExtra(BatteryManager.EXTRA_STATUS, -1);
+ return (status == BatteryManager.BATTERY_STATUS_CHARGING
+ || status == BatteryManager.BATTERY_STATUS_FULL);
+
+ }
}
diff --git a/core/src/main/java/de/danoeh/antennapod/core/feed/ChapterMerger.java b/core/src/main/java/de/danoeh/antennapod/core/util/ChapterMerger.java
index 9bbab7251..794b2322d 100644
--- a/core/src/main/java/de/danoeh/antennapod/core/feed/ChapterMerger.java
+++ b/core/src/main/java/de/danoeh/antennapod/core/util/ChapterMerger.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.core.feed;
+package de.danoeh.antennapod.core.util;
import android.text.TextUtils;
import android.util.Log;
diff --git a/core/src/main/java/de/danoeh/antennapod/core/util/ChapterUtils.java b/core/src/main/java/de/danoeh/antennapod/core/util/ChapterUtils.java
index 1af81802b..b32b05236 100644
--- a/core/src/main/java/de/danoeh/antennapod/core/util/ChapterUtils.java
+++ b/core/src/main/java/de/danoeh/antennapod/core/util/ChapterUtils.java
@@ -7,7 +7,6 @@ import android.text.TextUtils;
import android.util.Log;
import androidx.annotation.NonNull;
import de.danoeh.antennapod.model.feed.Chapter;
-import de.danoeh.antennapod.core.feed.ChapterMerger;
import de.danoeh.antennapod.model.feed.FeedMedia;
import de.danoeh.antennapod.net.common.AntennapodHttpClient;
import de.danoeh.antennapod.storage.database.DBReader;
diff --git a/core/src/main/java/de/danoeh/antennapod/core/dialog/ConfirmationDialog.java b/core/src/main/java/de/danoeh/antennapod/core/util/ConfirmationDialog.java
index b964c7508..ff5e56f5d 100644
--- a/core/src/main/java/de/danoeh/antennapod/core/dialog/ConfirmationDialog.java
+++ b/core/src/main/java/de/danoeh/antennapod/core/util/ConfirmationDialog.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.core.dialog;
+package de.danoeh.antennapod.core.util;
import android.content.Context;
import android.content.DialogInterface;
diff --git a/core/src/main/java/de/danoeh/antennapod/core/util/PowerUtils.java b/core/src/main/java/de/danoeh/antennapod/core/util/PowerUtils.java
deleted file mode 100644
index a1fadb4dc..000000000
--- a/core/src/main/java/de/danoeh/antennapod/core/util/PowerUtils.java
+++ /dev/null
@@ -1,30 +0,0 @@
-package de.danoeh.antennapod.core.util;
-
-import android.content.Context;
-import android.content.Intent;
-import android.content.IntentFilter;
-import android.os.BatteryManager;
-
-/**
- * Created by Tom on 1/5/15.
- */
-public class PowerUtils {
-
- private PowerUtils() {
-
- }
-
- /**
- * @return true if the device is charging
- */
- public static boolean deviceCharging(Context context) {
- // from http://developer.android.com/training/monitoring-device-state/battery-monitoring.html
- IntentFilter iFilter = new IntentFilter(Intent.ACTION_BATTERY_CHANGED);
- Intent batteryStatus = context.registerReceiver(null, iFilter);
-
- int status = batteryStatus.getIntExtra(BatteryManager.EXTRA_STATUS, -1);
- return (status == BatteryManager.BATTERY_STATUS_CHARGING ||
- status == BatteryManager.BATTERY_STATUS_FULL);
-
- }
-}
diff --git a/core/src/main/java/de/danoeh/antennapod/core/util/download/NetworkConnectionChangeHandler.java b/core/src/main/java/de/danoeh/antennapod/core/util/download/NetworkConnectionChangeHandler.java
deleted file mode 100644
index 79c6e76e1..000000000
--- a/core/src/main/java/de/danoeh/antennapod/core/util/download/NetworkConnectionChangeHandler.java
+++ /dev/null
@@ -1,29 +0,0 @@
-package de.danoeh.antennapod.core.util.download;
-
-import android.content.Context;
-import android.util.Log;
-import de.danoeh.antennapod.net.download.serviceinterface.AutoDownloadManager;
-import de.danoeh.antennapod.net.download.serviceinterface.DownloadServiceInterface;
-import de.danoeh.antennapod.net.common.NetworkUtils;
-
-public abstract class NetworkConnectionChangeHandler {
- private static final String TAG = "NetConnChangeHandler";
- private static Context context;
-
- public static void init(Context context) {
- NetworkConnectionChangeHandler.context = context;
- }
-
- public static void networkChangedDetected() {
- if (NetworkUtils.isAutoDownloadAllowed()) {
- Log.d(TAG, "auto-dl network available, starting auto-download");
- AutoDownloadManager.getInstance().autodownloadUndownloadedItems(context);
- } else { // if new network is Wi-Fi, finish ongoing downloads,
- // otherwise cancel all downloads
- if (NetworkUtils.isNetworkRestricted()) {
- Log.i(TAG, "Device is no longer connected to Wi-Fi. Cancelling ongoing downloads");
- DownloadServiceInterface.get().cancelAll(context);
- }
- }
- }
-}
diff --git a/core/src/test/java/android/text/TextUtils.java b/core/src/test/java/android/text/TextUtils.java
deleted file mode 100644
index 709cb9e93..000000000
--- a/core/src/test/java/android/text/TextUtils.java
+++ /dev/null
@@ -1,42 +0,0 @@
-package android.text;
-
-/**
- * A slim-down version of standard {@link android.text.TextUtils} to be used in unit tests.
- */
-public class TextUtils {
-
- /**
- * Returns true if a and b are equal, including if they are both null.
- * <p><i>Note: In platform versions 1.1 and earlier, this method only worked well if
- * both the arguments were instances of String.</i></p>
- * @param a first CharSequence to check
- * @param b second CharSequence to check
- * @return true if a and b are equal
- */
- @SuppressWarnings("unused")
- public static boolean equals(CharSequence a, CharSequence b) {
- if (a == b) return true;
- int length;
- if (a != null && b != null && (length = a.length()) == b.length()) {
- if (a instanceof String && b instanceof String) {
- return a.equals(b);
- } else {
- for (int i = 0; i < length; i++) {
- if (a.charAt(i) != b.charAt(i)) return false;
- }
- return true;
- }
- }
- return false;
- }
-
- /**
- * Returns <code>true</code> if the string is <code>null</code> or has zero length.
- *
- * @param str The string to be examined, can be <code>null</code>.
- * @return <code>true</code> if the string is <code>null</code> or has zero length.
- */
- public static boolean isEmpty(CharSequence str) {
- return str == null || str.length() == 0;
- }
-}
diff --git a/model/build.gradle b/model/build.gradle
index 5afbdf109..fa0f3679c 100644
--- a/model/build.gradle
+++ b/model/build.gradle
@@ -14,6 +14,8 @@ android {
dependencies {
annotationProcessor "androidx.annotation:annotation:$annotationVersion"
implementation "androidx.media:media:$mediaVersion"
-
implementation "org.apache.commons:commons-lang3:$commonslangVersion"
+
+ testImplementation "junit:junit:$junitVersion"
+ testImplementation "androidx.test:core:$testCoreVersion"
}
diff --git a/model/src/main/java/de/danoeh/antennapod/model/feed/Feed.java b/model/src/main/java/de/danoeh/antennapod/model/feed/Feed.java
index 8d36d24a3..15d256c24 100644
--- a/model/src/main/java/de/danoeh/antennapod/model/feed/Feed.java
+++ b/model/src/main/java/de/danoeh/antennapod/model/feed/Feed.java
@@ -1,12 +1,11 @@
package de.danoeh.antennapod.model.feed;
-import android.text.TextUtils;
-
import androidx.annotation.Nullable;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
+import org.apache.commons.lang3.StringUtils;
/**
* Data Object for a whole feed.
@@ -205,9 +204,9 @@ public class Feed {
}
public String getHumanReadableIdentifier() {
- if (!TextUtils.isEmpty(customTitle)) {
+ if (!StringUtils.isEmpty(customTitle)) {
return customTitle;
- } else if (!TextUtils.isEmpty(feedTitle)) {
+ } else if (!StringUtils.isEmpty(feedTitle)) {
return feedTitle;
} else {
return downloadUrl;
@@ -266,7 +265,7 @@ public class Feed {
}
public String getTitle() {
- return !TextUtils.isEmpty(customTitle) ? customTitle : feedTitle;
+ return !StringUtils.isEmpty(customTitle) ? customTitle : feedTitle;
}
public void setTitle(String title) {
diff --git a/model/src/main/java/de/danoeh/antennapod/model/playback/RemoteMedia.java b/model/src/main/java/de/danoeh/antennapod/model/playback/RemoteMedia.java
index b963f3de1..c979488a6 100644
--- a/model/src/main/java/de/danoeh/antennapod/model/playback/RemoteMedia.java
+++ b/model/src/main/java/de/danoeh/antennapod/model/playback/RemoteMedia.java
@@ -3,7 +3,6 @@ package de.danoeh.antennapod.model.playback;
import android.content.Context;
import android.os.Parcel;
import android.os.Parcelable;
-import android.text.TextUtils;
import androidx.annotation.Nullable;
import de.danoeh.antennapod.model.feed.Chapter;
import de.danoeh.antennapod.model.feed.Feed;
@@ -13,6 +12,7 @@ import de.danoeh.antennapod.model.feed.FeedMedia;
import java.util.Date;
import java.util.List;
+import org.apache.commons.lang3.StringUtils;
import org.apache.commons.lang3.builder.HashCodeBuilder;
/**
@@ -68,7 +68,7 @@ public class RemoteMedia implements Playable {
this.episodeTitle = item.getTitle();
this.episodeLink = item.getLink();
this.feedAuthor = item.getFeed().getAuthor();
- if (!TextUtils.isEmpty(item.getImageUrl())) {
+ if (!StringUtils.isEmpty(item.getImageUrl())) {
this.imageUrl = item.getImageUrl();
} else {
this.imageUrl = item.getFeed().getImageUrl();
@@ -280,21 +280,21 @@ public class RemoteMedia implements Playable {
public boolean equals(Object other) {
if (other instanceof RemoteMedia) {
RemoteMedia rm = (RemoteMedia) other;
- return TextUtils.equals(downloadUrl, rm.downloadUrl)
- && TextUtils.equals(feedUrl, rm.feedUrl)
- && TextUtils.equals(itemIdentifier, rm.itemIdentifier);
+ return StringUtils.equals(downloadUrl, rm.downloadUrl)
+ && StringUtils.equals(feedUrl, rm.feedUrl)
+ && StringUtils.equals(itemIdentifier, rm.itemIdentifier);
}
if (other instanceof FeedMedia) {
FeedMedia fm = (FeedMedia) other;
- if (!TextUtils.equals(downloadUrl, fm.getStreamUrl())) {
+ if (!StringUtils.equals(downloadUrl, fm.getStreamUrl())) {
return false;
}
FeedItem fi = fm.getItem();
- if (fi == null || !TextUtils.equals(itemIdentifier, fi.getItemIdentifier())) {
+ if (fi == null || !StringUtils.equals(itemIdentifier, fi.getItemIdentifier())) {
return false;
}
Feed feed = fi.getFeed();
- return feed != null && TextUtils.equals(feedUrl, feed.getDownloadUrl());
+ return feed != null && StringUtils.equals(feedUrl, feed.getDownloadUrl());
}
return false;
}
diff --git a/core/src/test/java/de/danoeh/antennapod/core/feed/VolumeAdaptionSettingTest.java b/model/src/test/java/de/danoeh/antennapod/model/VolumeAdaptionSettingTest.java
index 966351a5e..265b425e8 100644
--- a/core/src/test/java/de/danoeh/antennapod/core/feed/VolumeAdaptionSettingTest.java
+++ b/model/src/test/java/de/danoeh/antennapod/model/VolumeAdaptionSettingTest.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.core.feed;
+package de.danoeh.antennapod.model;
import de.danoeh.antennapod.model.feed.VolumeAdaptionSetting;
@@ -6,8 +6,8 @@ import org.junit.After;
import org.junit.Before;
import org.junit.Test;
-import static org.hamcrest.Matchers.equalTo;
-import static org.hamcrest.Matchers.is;
+import static org.hamcrest.CoreMatchers.equalTo;
+import static org.hamcrest.CoreMatchers.is;
import static org.junit.Assert.assertEquals;
import static org.hamcrest.MatcherAssert.assertThat;
import static org.junit.Assert.assertTrue;
diff --git a/core/src/test/java/de/danoeh/antennapod/core/util/FilenameGeneratorTest.java b/net/download/service-interface/src/test/java/de/danoeh/antennapod/net/download/serviceinterface/FilenameGeneratorTest.java
index 4c225322a..521fc2d36 100644
--- a/core/src/test/java/de/danoeh/antennapod/core/util/FilenameGeneratorTest.java
+++ b/net/download/service-interface/src/test/java/de/danoeh/antennapod/net/download/serviceinterface/FilenameGeneratorTest.java
@@ -1,11 +1,10 @@
-package de.danoeh.antennapod.core.util;
+package de.danoeh.antennapod.net.download.serviceinterface;
import androidx.test.platform.app.InstrumentationRegistry;
import android.text.TextUtils;
import java.io.File;
-import de.danoeh.antennapod.net.download.serviceinterface.FileNameGenerator;
import org.apache.commons.lang3.StringUtils;
import org.junit.Test;
import org.junit.runner.RunWith;
diff --git a/net/download/service/src/main/AndroidManifest.xml b/net/download/service/src/main/AndroidManifest.xml
index 240319a5e..89b6823e5 100644
--- a/net/download/service/src/main/AndroidManifest.xml
+++ b/net/download/service/src/main/AndroidManifest.xml
@@ -14,6 +14,24 @@
android:label="@string/feed_update_receiver_name"
android:exported="true"
tools:ignore="ExportedReceiver" /> <!-- allow feeds update to be triggered by external apps -->
+
+ <receiver
+ android:name=".ConnectivityActionReceiver"
+ android:exported="true">
+ <intent-filter>
+ <action android:name="android.net.conn.CONNECTIVITY_CHANGE" tools:ignore="BatteryLife"/>
+ </intent-filter>
+ </receiver>
+
+ <receiver
+ android:name=".PowerConnectionReceiver"
+ android:exported="true">
+ <intent-filter>
+ <action android:name="android.intent.action.ACTION_POWER_CONNECTED"/>
+ <action android:name="android.intent.action.ACTION_POWER_DISCONNECTED"/>
+ </intent-filter>
+ </receiver>
+
</application>
</manifest>
diff --git a/net/download/service/src/main/java/de/danoeh/antennapod/net/download/service/ConnectivityActionReceiver.java b/net/download/service/src/main/java/de/danoeh/antennapod/net/download/service/ConnectivityActionReceiver.java
new file mode 100644
index 000000000..3b733a482
--- /dev/null
+++ b/net/download/service/src/main/java/de/danoeh/antennapod/net/download/service/ConnectivityActionReceiver.java
@@ -0,0 +1,34 @@
+package de.danoeh.antennapod.net.download.service;
+
+import android.content.BroadcastReceiver;
+import android.content.Context;
+import android.content.Intent;
+import android.net.ConnectivityManager;
+import android.text.TextUtils;
+import android.util.Log;
+
+import de.danoeh.antennapod.net.common.NetworkUtils;
+import de.danoeh.antennapod.net.download.serviceinterface.AutoDownloadManager;
+import de.danoeh.antennapod.net.download.serviceinterface.DownloadServiceInterface;
+
+public class ConnectivityActionReceiver extends BroadcastReceiver {
+ private static final String TAG = "ConnectivityActionRecvr";
+
+ @Override
+ public void onReceive(final Context context, Intent intent) {
+ if (TextUtils.equals(intent.getAction(), ConnectivityManager.CONNECTIVITY_ACTION)) {
+ Log.d(TAG, "Received intent");
+
+ if (NetworkUtils.isAutoDownloadAllowed()) {
+ Log.d(TAG, "auto-dl network available, starting auto-download");
+ AutoDownloadManager.getInstance().autodownloadUndownloadedItems(context);
+ } else { // if new network is Wi-Fi, finish ongoing downloads,
+ // otherwise cancel all downloads
+ if (NetworkUtils.isNetworkRestricted()) {
+ Log.i(TAG, "Device is no longer connected to Wi-Fi. Cancelling ongoing downloads");
+ DownloadServiceInterface.get().cancelAll(context);
+ }
+ }
+ }
+ }
+}
diff --git a/app/src/main/java/de/danoeh/antennapod/receiver/PowerConnectionReceiver.java b/net/download/service/src/main/java/de/danoeh/antennapod/net/download/service/PowerConnectionReceiver.java
index 6e179647e..12a3f82e0 100644
--- a/app/src/main/java/de/danoeh/antennapod/receiver/PowerConnectionReceiver.java
+++ b/net/download/service/src/main/java/de/danoeh/antennapod/net/download/service/PowerConnectionReceiver.java
@@ -1,11 +1,10 @@
-package de.danoeh.antennapod.receiver;
+package de.danoeh.antennapod.net.download.service;
import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.util.Log;
-import de.danoeh.antennapod.ClientConfigurator;
import de.danoeh.antennapod.net.download.serviceinterface.AutoDownloadManager;
import de.danoeh.antennapod.storage.preferences.UserPreferences;
import de.danoeh.antennapod.net.download.serviceinterface.DownloadServiceInterface;
@@ -24,7 +23,6 @@ public class PowerConnectionReceiver extends BroadcastReceiver {
Log.d(TAG, "charging intent: " + action);
- ClientConfigurator.initialize(context);
if (Intent.ACTION_POWER_CONNECTED.equals(action)) {
Log.d(TAG, "charging, starting auto-download");
// we're plugged in, this is a great time to auto-download if everything else is
diff --git a/storage/database/build.gradle b/storage/database/build.gradle
index 63f9eeaec..a78afbf79 100644
--- a/storage/database/build.gradle
+++ b/storage/database/build.gradle
@@ -28,6 +28,9 @@ dependencies {
implementation "commons-io:commons-io:$commonsioVersion"
implementation "org.greenrobot:eventbus:$eventbusVersion"
implementation "com.google.guava:guava:31.0.1-android"
+ implementation "org.apache.commons:commons-lang3:$commonslangVersion"
testImplementation "junit:junit:$junitVersion"
+ testImplementation "androidx.test:core:$testCoreVersion"
+ testImplementation "org.robolectric:robolectric:$robolectricVersion"
}
diff --git a/storage/database/src/main/java/de/danoeh/antennapod/storage/database/FeedItemDuplicateGuesser.java b/storage/database/src/main/java/de/danoeh/antennapod/storage/database/FeedItemDuplicateGuesser.java
index bbaedb519..19a2bd5f1 100644
--- a/storage/database/src/main/java/de/danoeh/antennapod/storage/database/FeedItemDuplicateGuesser.java
+++ b/storage/database/src/main/java/de/danoeh/antennapod/storage/database/FeedItemDuplicateGuesser.java
@@ -1,11 +1,11 @@
package de.danoeh.antennapod.storage.database;
-import android.text.TextUtils;
import de.danoeh.antennapod.model.feed.FeedItem;
import de.danoeh.antennapod.model.feed.FeedMedia;
import java.text.DateFormat;
import java.util.Locale;
+import org.apache.commons.lang3.StringUtils;
/**
* Publishers sometimes mess up their feed by adding episodes twice or by changing the ID of existing episodes.
@@ -32,7 +32,7 @@ public class FeedItemDuplicateGuesser {
}
public static boolean sameAndNotEmpty(String string1, String string2) {
- if (TextUtils.isEmpty(string1) || TextUtils.isEmpty(string2)) {
+ if (StringUtils.isEmpty(string1) || StringUtils.isEmpty(string2)) {
return false;
}
return string1.equals(string2);
@@ -45,7 +45,7 @@ public class FeedItemDuplicateGuesser {
DateFormat dateFormat = DateFormat.getDateInstance(DateFormat.SHORT, Locale.US); // MM/DD/YY
String dateOriginal = dateFormat.format(item2.getPubDate());
String dateNew = dateFormat.format(item1.getPubDate());
- return TextUtils.equals(dateOriginal, dateNew); // Same date; time is ignored.
+ return StringUtils.equals(dateOriginal, dateNew); // Same date; time is ignored.
}
private static boolean durationsLookSimilar(FeedMedia media1, FeedMedia media2) {
@@ -62,7 +62,7 @@ public class FeedItemDuplicateGuesser {
mimeType1 = mimeType1.substring(0, mimeType1.indexOf("/"));
mimeType2 = mimeType2.substring(0, mimeType2.indexOf("/"));
}
- return TextUtils.equals(mimeType1, mimeType2);
+ return StringUtils.equals(mimeType1, mimeType2);
}
private static boolean titlesLookSimilar(FeedItem item1, FeedItem item2) {
diff --git a/core/src/test/java/de/danoeh/antennapod/core/util/FeedItemPermutorsTest.java b/storage/database/src/test/java/de/danoeh/antennapod/storage/database/FeedItemPermutorsTest.java
index 4ebff066e..9e0f106fd 100644
--- a/core/src/test/java/de/danoeh/antennapod/core/util/FeedItemPermutorsTest.java
+++ b/storage/database/src/test/java/de/danoeh/antennapod/storage/database/FeedItemPermutorsTest.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.core.util;
+package de.danoeh.antennapod.storage.database;
import de.danoeh.antennapod.model.feed.SortOrder;
import de.danoeh.antennapod.storage.database.FeedItemPermutors;
diff --git a/core/src/test/java/de/danoeh/antennapod/core/storage/mapper/FeedCursorMapperTest.java b/storage/database/src/test/java/de/danoeh/antennapod/storage/database/mapper/FeedCursorMapperTest.java
index 87ade0c6f..5e7a4843e 100644
--- a/core/src/test/java/de/danoeh/antennapod/core/storage/mapper/FeedCursorMapperTest.java
+++ b/storage/database/src/test/java/de/danoeh/antennapod/storage/database/mapper/FeedCursorMapperTest.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.core.storage.mapper;
+package de.danoeh.antennapod.storage.database.mapper;
import android.content.ContentValues;
import android.content.Context;
@@ -7,7 +7,6 @@ import android.database.Cursor;
import androidx.test.platform.app.InstrumentationRegistry;
import de.danoeh.antennapod.storage.database.PodDBAdapter;
-import de.danoeh.antennapod.storage.database.mapper.FeedCursorMapper;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
diff --git a/ui/common/build.gradle b/ui/common/build.gradle
index 26db9f9e4..1325761d3 100644
--- a/ui/common/build.gradle
+++ b/ui/common/build.gradle
@@ -16,4 +16,6 @@ dependencies {
implementation "androidx.viewpager2:viewpager2:$viewPager2Version"
implementation "com.google.android.material:material:$googleMaterialVersion"
implementation "androidx.core:core-splashscreen:1.0.0"
+
+ testImplementation "junit:junit:$junitVersion"
}
diff --git a/core/src/test/java/de/danoeh/antennapod/core/util/ConverterTest.java b/ui/common/src/test/java/de/danoeh/antennapod/ui/common/ConverterTest.java
index 2e4ead5e6..516490ff3 100644
--- a/core/src/test/java/de/danoeh/antennapod/core/util/ConverterTest.java
+++ b/ui/common/src/test/java/de/danoeh/antennapod/ui/common/ConverterTest.java
@@ -1,4 +1,4 @@
-package de.danoeh.antennapod.core.util;
+package de.danoeh.antennapod.ui.common;
import de.danoeh.antennapod.ui.common.Converter;
import org.junit.Test;
diff --git a/ui/statistics/src/main/java/de/danoeh/antennapod/ui/statistics/StatisticsFragment.java b/ui/statistics/src/main/java/de/danoeh/antennapod/ui/statistics/StatisticsFragment.java
index c5ec4cb59..a2f9e8146 100644
--- a/ui/statistics/src/main/java/de/danoeh/antennapod/ui/statistics/StatisticsFragment.java
+++ b/ui/statistics/src/main/java/de/danoeh/antennapod/ui/statistics/StatisticsFragment.java
@@ -18,7 +18,7 @@ import androidx.viewpager2.widget.ViewPager2;
import com.google.android.material.tabs.TabLayout;
import com.google.android.material.tabs.TabLayoutMediator;
-import de.danoeh.antennapod.core.dialog.ConfirmationDialog;
+import de.danoeh.antennapod.core.util.ConfirmationDialog;
import de.danoeh.antennapod.storage.database.DBWriter;
import de.danoeh.antennapod.event.StatisticsEvent;
import de.danoeh.antennapod.ui.common.PagedToolbarFragment;