[Android] Fix empty playlist screen on initial load
Robert Stone
git at videolan.org
Tue Jul 27 05:40:35 UTC 2021
vlc-android | branch: master | Robert Stone <rhstone at gmail.com> | Mon Jul 26 20:35:34 2021 -0700| [3db60a43f842e54a146655f41e6ab323cde7b5e6] | committer: Robert Stone
Fix empty playlist screen on initial load
Fixes #2110
> https://code.videolan.org/videolan/vlc-android/commit/3db60a43f842e54a146655f41e6ab323cde7b5e6
---
.../vlc-android/src/org/videolan/vlc/gui/PlaylistFragment.kt | 6 +-----
1 file changed, 1 insertion(+), 5 deletions(-)
diff --git a/application/vlc-android/src/org/videolan/vlc/gui/PlaylistFragment.kt b/application/vlc-android/src/org/videolan/vlc/gui/PlaylistFragment.kt
index e521c50d6..f137e98e8 100644
--- a/application/vlc-android/src/org/videolan/vlc/gui/PlaylistFragment.kt
+++ b/application/vlc-android/src/org/videolan/vlc/gui/PlaylistFragment.kt
@@ -122,12 +122,8 @@ class PlaylistFragment : BaseAudioBrowser<PlaylistsViewModel>(), SwipeRefreshLay
}
- override fun onResume() {
- swipeRefreshLayout.visibility = if (Medialibrary.getInstance().isInitiated) View.VISIBLE else View.GONE
- super.onResume()
- }
-
private fun updateEmptyView() {
+ swipeRefreshLayout.visibility = if (Medialibrary.getInstance().isInitiated) View.VISIBLE else View.GONE
binding.emptyLoading.state =
if (!Permissions.canReadStorage(AppContextProvider.appContext)) EmptyLoadingState.MISSING_PERMISSION else if (viewModel.provider.loading.value == true && empty) EmptyLoadingState.LOADING else if (empty) EmptyLoadingState.EMPTY else EmptyLoadingState.NONE
}
More information about the Android
mailing list