mdsami / android-query

Automatically exported from code.google.com/p/android-query
0 stars 0 forks source link

Scrolling with image loader in listview does not smooth #2

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Init listview items with more than 100 items (thumbnail images)
2. Fast scroll listview from top to bottom
3. Look does not smooth when scroll

What is the expected output? What do you see instead?
More smooth

What version of the product are you using? On what operating system?
newest version from svn

Please provide any additional information below.

Original issue reported on code.google.com by thanh.it...@gmail.com on 27 Sep 2011 at 5:03

GoogleCodeExporter commented 8 years ago
Seems related to scrolling too fast and causing images to load too quickly. 
Solution is to detect the list scroll speed and load images when the user stop 
fling.

Original comment by tinyeeliu@gmail.com on 27 Sep 2011 at 10:17

GoogleCodeExporter commented 8 years ago

Original comment by tinyeeliu@gmail.com on 1 Oct 2011 at 3:10

GoogleCodeExporter commented 8 years ago
Download:
http://code.google.com/p/android-query/downloads/list

Doc:
http://code.google.com/p/android-query/wiki/ImageLoading?ts=1317640729&updated=I
mageLoading#Delay_Image_Loading

Added a method called shouldDelay() that tells you whether the list is flinging 
to avoid loading images. 
This should help you to only load image when an AbsListView stops scrolling.

Let me know if this solves your performance issue.

Original comment by tinyeeliu@gmail.com on 3 Oct 2011 at 11:34