android 4.2.2의 Universal Image Loader 1.9.1에 문제가 있습니다. 여기에 설명 된 내용은 Android Universal image loader, stop retry입니다. NOSTRA 답변을 여러 번 읽었지만 구현 방법을 알 수 없습니다. BaseImageDownloader를 확장하고 getStream 메서드를 재정의해야합니까? 대답의 마지막 부분을 사용하고 싶습니다.유니버설 이미지 로더 재시도 중지
UIL은 이미지로드 자체를 다시 시도하지 않습니다. null을 반환하면 onLoadingFailed (...) 콜백이 발생합니다. 동일한 URL에 대해 displayImage (...)를 다시 호출하면 UIL은 이미지를 다시로드하려고 시도합니다. 당신이 그것을 막으려면 어딘가에 "불량"URL을 유지해야하며 ImageLoader를 이러한 URL ()을 호출하거나이 URL의 ImageDownloader에서 null null을 반환해야합니다..
기본적으로, UIL은 이상 유효하지 않은 이미지 파일에 대한 유효한 URL의 포인팅을 통해 연락을 시도하지 않도록하는 가장 간단한 방법은 무엇입니까? 내 응용 프로그램은 크게 UIL을 사용, 난 정말 여기에 몇 가지 도움이 필요
DisplayImageOptions options = new DisplayImageOptions.Builder()
.resetViewBeforeLoading(true).cacheInMemory(true)
.cacheOnDisc(true)
.imageScaleType(ImageScaleType.EXACTLY_STRETCHED)
.showImageForEmptyUri(R.drawable.photo_placeholder)
.showImageOnFail(R.drawable.photo_placeholder).build();
ImageLoaderConfiguration config = new ImageLoaderConfiguration.Builder(
context).memoryCacheExtraOptions(200, 200)
.discCacheExtraOptions(200, 200, CompressFormat.JPEG, 75, null)
.threadPoolSize(5).denyCacheImageMultipleSizesInMemory()
.memoryCache(new LruMemoryCache(2 * 1024 * 1024))
.imageDownloader(new BaseImageDownloader(context) {
})
.defaultDisplayImageOptions(options).build();
: 그것은 도움이 될 수 있다면 내가 여기, 내 설정을 모른다.