In my app iam trying to load the contact images using UniversaImageLoader, i ran into few problems, and have few queries
1) Eventhough when iam running the Uniimagloader alone on my phone iam getting the list but no images,
what am i doing wrong?
2) i used some of the code from that proj , and also loaded the jarfile but still iam getting folloing error
FATAL EXCEPTION: main
12-19 20:37:22.050: E/AndroidRuntime(10152): java.lang.NoClassDefFoundError: com.nostra13.universalimageloader.core.ImageLoader
12-19 20:37:22.050: E/AndroidRuntime(10152): at org.app.activity.BaseActivity.<init>(BaseActivity.java:11)
12-19 20:37:22.050: E/AndroidRuntime(10152): at org.app.activity.ProfileActivity.<init>(ProfileActivity.java:39)
12-19 20:37:22.050: E/AndroidRuntime(10152): at java.lang.Class.newInstanceImpl(Native Method)
12-19 20:37:22.050: E/AndroidRuntime(10152): at java.lang.Class.newInstance(Class.java:1301)
12-19 20:37:22.050: E/AndroidRuntime(10152): at android.app.Instrumentation.newActivity(Instrumentation.java:1022)
3) configuration for ImageLoader : iam doing this in my adapter , can i do that? doing this iam getting error at maxImageWidthForMemoryCache(800) it says Add cast to method reciever.
ImageLoaderConfiguration config = new ImageLoaderConfiguration.Builder(context)
.maxImageWidthForMemoryCache(800)
.maxImageHeightForMemoryCache(800)
.httpConnectTimeout(5000)
.httpReadTimeout(30000)
.threadPoolSize(5)
.threadPriority(Thread.MIN_PRIORITY + 2)
.denyCacheImageMultipleSizesInMemory()
.memoryCache(new UsingFreqLimitedMemoryCache(2000000))
.discCache(new UnlimitedDiscCache(cacheDir))
.defaultDisplayImageOptions(DisplayImageOptions.createSimple())
.build();
I am struck. Any help is appreciated.
Try to make sure that context variable is an Activity instance. It has this kind of error in the past.