[Android] Prevent ClassCastException
Geoffrey Métais
git at videolan.org
Wed Nov 16 15:54:21 CET 2016
vlc-android | branch: master | Geoffrey Métais <geoffrey.metais at gmail.com> | Wed Nov 16 15:31:06 2016 +0100| [dc4ce43549aa18b78dd7b282f4fa5a31ae004102] | committer: Geoffrey Métais
Prevent ClassCastException
> https://code.videolan.org/videolan/vlc-android/commit/dc4ce43549aa18b78dd7b282f4fa5a31ae004102
---
vlc-android/src/org/videolan/vlc/gui/helpers/AsyncImageLoader.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/vlc-android/src/org/videolan/vlc/gui/helpers/AsyncImageLoader.java b/vlc-android/src/org/videolan/vlc/gui/helpers/AsyncImageLoader.java
index e9b4f85..d7370ad 100644
--- a/vlc-android/src/org/videolan/vlc/gui/helpers/AsyncImageLoader.java
+++ b/vlc-android/src/org/videolan/vlc/gui/helpers/AsyncImageLoader.java
@@ -259,7 +259,7 @@ public class AsyncImageLoader {
@Override
public void updateImage(Bitmap bitmap, View target) {
- updateTargetImage(bitmap, target, binding, ((MediaWrapper) item).getType());
+ updateTargetImage(bitmap, target, binding, item.getItemType() == MediaLibraryItem.TYPE_MEDIA ? ((MediaWrapper) item).getType() : MediaWrapper.TYPE_AUDIO);
}
}
More information about the Android
mailing list