[Android] Fix hasPendingUpdates() in DiffUtilAdapter
Geoffrey Métais
git at videolan.org
Wed Dec 20 12:59:19 CET 2017
vlc-android | branch: master | Geoffrey Métais <geoffrey.metais at gmail.com> | Wed Dec 20 12:01:21 2017 +0100| [a6b454e62b97407ed67d74cecd62b464df69cd47] | committer: Geoffrey Métais
Fix hasPendingUpdates() in DiffUtilAdapter
> https://code.videolan.org/videolan/vlc-android/commit/a6b454e62b97407ed67d74cecd62b464df69cd47
---
vlc-android/src/org/videolan/vlc/gui/DiffUtilAdapter.kt | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/vlc-android/src/org/videolan/vlc/gui/DiffUtilAdapter.kt b/vlc-android/src/org/videolan/vlc/gui/DiffUtilAdapter.kt
index 38f500533..75be327ce 100644
--- a/vlc-android/src/org/videolan/vlc/gui/DiffUtilAdapter.kt
+++ b/vlc-android/src/org/videolan/vlc/gui/DiffUtilAdapter.kt
@@ -34,7 +34,7 @@ abstract class DiffUtilAdapter<D : MediaLibraryItem, VH : RecyclerView.ViewHolde
launch(UI) {
dataset = finalList
result.dispatchUpdatesTo(this at DiffUtilAdapter)
- if (!updateActor.isFull) onUpdateFinished()
+ onUpdateFinished()
}.join()
}
@@ -42,7 +42,7 @@ abstract class DiffUtilAdapter<D : MediaLibraryItem, VH : RecyclerView.ViewHolde
fun peekLast() = last
- fun hasPendingUpdates() = last !== dataset
+ fun hasPendingUpdates() = updateActor.isFull
open protected fun detectMoves() = false
More information about the Android
mailing list