[Android] TV: Load UPnP icons
Geoffrey Métais
git at videolan.org
Thu Feb 18 11:14:54 CET 2016
vlc-android | branch: master | Geoffrey Métais <geoffrey.metais at gmail.com> | Thu Feb 18 11:13:45 2016 +0100| [69cd9a507821e8529fdc9a28eb56bf6c603831b5] | committer: Geoffrey Métais
TV: Load UPnP icons
> https://code.videolan.org/videolan/vlc-android/commit/69cd9a507821e8529fdc9a28eb56bf6c603831b5
---
vlc-android/src/org/videolan/vlc/gui/tv/CardPresenter.java | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/vlc-android/src/org/videolan/vlc/gui/tv/CardPresenter.java b/vlc-android/src/org/videolan/vlc/gui/tv/CardPresenter.java
index 131d0b4..abf35be 100644
--- a/vlc-android/src/org/videolan/vlc/gui/tv/CardPresenter.java
+++ b/vlc-android/src/org/videolan/vlc/gui/tv/CardPresenter.java
@@ -31,6 +31,7 @@ import android.net.Uri;
import android.os.Build;
import android.support.v17.leanback.widget.ImageCardView;
import android.support.v17.leanback.widget.Presenter;
+import android.text.TextUtils;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ImageView;
@@ -42,6 +43,7 @@ import org.videolan.vlc.gui.helpers.BitmapUtil;
import org.videolan.vlc.gui.tv.browser.MusicFragment;
import org.videolan.vlc.media.MediaDatabase;
import org.videolan.vlc.media.MediaWrapper;
+import org.videolan.vlc.util.HttpImageLoader;
@TargetApi(Build.VERSION_CODES.JELLY_BEAN_MR1)
public class CardPresenter extends Presenter {
@@ -233,6 +235,8 @@ public class CardPresenter extends Presenter {
@Override
public void updateImage(final Bitmap picture, final View target) {
+ if (!TextUtils.isEmpty(mediaWrapper.getArtworkURL()) && mediaWrapper.getArtworkURL().startsWith("http"))
+ AsyncImageLoader.LoadImage(new HttpImageLoader(mediaWrapper.getArtworkURL()), target);
context.runOnUiThread(
new Runnable() {
@Override
More information about the Android
mailing list