[Android] Paging: Increase page size
Geoffrey Métais
git at videolan.org
Fri Feb 15 15:56:51 CET 2019
vlc-android | branch: master | Geoffrey Métais <geoffrey.metais at gmail.com> | Fri Feb 15 15:38:56 2019 +0100| [e6f92a8469af105ae56e4c036c176d6968e8436a] | committer: Geoffrey Métais
Paging: Increase page size
> https://code.videolan.org/videolan/vlc-android/commit/e6f92a8469af105ae56e4c036c176d6968e8436a
---
vlc-android/src/org/videolan/vlc/util/Constants.kt | 2 +-
vlc-android/src/org/videolan/vlc/viewmodels/paged/MLPagedModel.kt | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/vlc-android/src/org/videolan/vlc/util/Constants.kt b/vlc-android/src/org/videolan/vlc/util/Constants.kt
index 878f4f00e..11eb46449 100644
--- a/vlc-android/src/org/videolan/vlc/util/Constants.kt
+++ b/vlc-android/src/org/videolan/vlc/util/Constants.kt
@@ -63,7 +63,7 @@ const val PLAYLIST_TYPE_VIDEO = 1
const val REPEAT_NONE = 0
const val REPEAT_ONE = 1
const val REPEAT_ALL = 2
-const val MEDIALIBRARY_PAGE_SIZE = 100
+const val MEDIALIBRARY_PAGE_SIZE = 500
// MediaParsingService
diff --git a/vlc-android/src/org/videolan/vlc/viewmodels/paged/MLPagedModel.kt b/vlc-android/src/org/videolan/vlc/viewmodels/paged/MLPagedModel.kt
index 3eef2b154..5f5ce084c 100644
--- a/vlc-android/src/org/videolan/vlc/viewmodels/paged/MLPagedModel.kt
+++ b/vlc-android/src/org/videolan/vlc/viewmodels/paged/MLPagedModel.kt
@@ -27,7 +27,7 @@ abstract class MLPagedModel<T : MediaLibraryItem>(context: Context) : SortableMo
private val pagingConfig = PagedList.Config.Builder()
.setPageSize(MEDIALIBRARY_PAGE_SIZE)
- .setPrefetchDistance(MEDIALIBRARY_PAGE_SIZE/2)
+ .setPrefetchDistance(MEDIALIBRARY_PAGE_SIZE/5)
.setEnablePlaceholders(true)
.build()
More information about the Android
mailing list