Titanium JIRA Archive
Appcelerator Community (AC)

[AC-3874] [ANDROID] ListView image scrolling very jerky (even after following the best practices)

GitHub Issuen/a
TypeBug
Priorityn/a
StatusClosed
ResolutionFixed
Resolution Date2016-06-21T18:57:31.000+0000
Affected Version/sn/a
Fix Version/sn/a
ComponentsTitanium SDK & CLI
LabelsImageview, ListView, Scroll, android, template
ReporterLee phela
AssigneeShak Hossain
Created2016-06-16T19:35:35.000+0000
Updated2016-06-21T18:57:31.000+0000

Description

var lf=10,rt=10;
var template={
		childTemplates:[
			{
				type:"Ti.UI.View",
				properties:{
					left:rt,
					right:rt
				},
				events:{
					longpress:function(e){
					}
				},
				childTemplates:[
					{
						type:"Ti.UI.View",
						properties:{
							height:80,
							width:120,
							left:0,
							borderRadius:5
						},
						childTemplates:[
							{
								type:"Ti.UI.ImageView",
								bindId:"thumb",
								properties:{
									height:80,
									width:120,
									defaultImage:"/images/default.png"
								}
							},
							{
								type:"Ti.UI.Label",
								bindId:"dur",
								properties:{
									bottom:3,
									right:3,
									font:{fontSize:12},
									backgroundColor:"#000",
									color:"#FFF"
								}
							}
						]
					},
					{
						type:"Ti.UI.Label",
						bindId:"myTitle",
						properties:{
							left:125,
							right:0,
							wordWrap:false,
							ellipsize:Ti.UI.TEXT_ELLIPSIZE_TRUNCATE_END,
							font:{fontSize:13},
							color:G.tColor
						}
					}
				]
			}
		]
	};
Above are the template for my listview. The purpose of using listview is to improve performance and to reduce overhead in creating multiple views, but instead, there is a lot of choppiness in the scrolling that it makes the UI experience absolutely horrible. To be precise, the scrolling stops until the next visible image in the queue is fully loaded and then only it continues to scroll again. This problem has given to a lot of users a horrible user experience, and I find most of them trying to skip from anything inside the app that involves about scrolling! The listview with no imageview inside them works fine as normal but anything that contains images, the extend of choppiness is damm unbearable! All images used in the listview are cached version.

Comments

  1. Lee phela 2016-06-16

    Actually, I was displaying my listview inside an alertDialog as android view. However, after ditching alertDialog and switching to a full window activity, the jerkiness and choppiness disappears completely. Admin may close this ticket as resolved and for anyone coming here with similar issues, always use the listview on the window activity directly and not on the alertdialog or whatever!
  2. Sharif AbuDarda 2016-06-21

    Hello, Thanks for letting us know. Yes, listview should be used in window directly.

JSON Source