mirror of
https://github.com/TeamNewPipe/NewPipe
synced 2024-12-20 15:49:50 +01:00
Merge pull request #545 from mauriciocolli/fix-image-loader
Fix image loading bug
This commit is contained in:
commit
e07464b81c
@ -189,6 +189,7 @@ public abstract class BasePlayer implements ExoPlayer.EventListener, AudioManage
|
||||
ImageLoader.getInstance().loadImage(videoThumbnailUrl, new SimpleImageLoadingListener() {
|
||||
@Override
|
||||
public void onLoadingComplete(String imageUri, View view, Bitmap loadedImage) {
|
||||
if (simpleExoPlayer == null) return;
|
||||
if (DEBUG) Log.d(TAG, "onLoadingComplete() called with: imageUri = [" + imageUri + "], view = [" + view + "], loadedImage = [" + loadedImage + "]");
|
||||
videoThumbnail = loadedImage;
|
||||
onThumbnailReceived(loadedImage);
|
||||
|
@ -677,7 +677,9 @@ public class PopupVideoPlayer extends Service {
|
||||
imageLoader.resume();
|
||||
imageLoader.loadImage(info.thumbnail_url, displayImageOptions, new SimpleImageLoadingListener() {
|
||||
@Override
|
||||
public void onLoadingComplete(String imageUri, View view, final Bitmap loadedImage) {
|
||||
public void onLoadingComplete(final String imageUri, View view, final Bitmap loadedImage) {
|
||||
if (playerImpl == null || playerImpl.getPlayer() == null) return;
|
||||
if (DEBUG) Log.d(TAG, "FetcherRunnable.imageLoader.onLoadingComplete() called with: imageUri = [" + imageUri + "]");
|
||||
mainHandler.post(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
|
Loading…
Reference in New Issue
Block a user