{ "id": "116165", "key": "TIMOB-14290", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "10153", "key": "TIMOB", "name": "Titanium SDK/CLI", "projectCategory": { "id": "10100", "description": "Titanium and related SDKs used in application development", "name": "Client" } }, "fixVersions": [ { "id": "15719", "description": "2013 Sprint 26", "name": "2013 Sprint 26", "archived": true, "released": true, "releaseDate": "2014-01-03" }, { "id": "15720", "description": "2013 Sprint 26 API", "name": "2013 Sprint 26 API", "archived": true, "released": true, "releaseDate": "2014-01-03" }, { "id": "15856", "description": "Release 3.2.1", "name": "Release 3.2.1", "archived": false, "released": true, "releaseDate": "2014-02-10" }, { "id": "15422", "description": "Release 3.3.0", "name": "Release 3.3.0", "archived": false, "released": true, "releaseDate": "2014-07-16" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2014-01-02T21:30:49.000+0000", "created": "2013-06-19T11:39:02.000+0000", "priority": { "name": "Medium", "id": "3" }, "labels": [ "ios", "listview", "module_listview", "parity", "qe-testadded", "scrollToItem", "supportTeam" ], "versions": [ { "id": "15478", "description": "Release 3.1.1", "name": "Release 3.1.1", "archived": true, "released": true, "releaseDate": "2013-06-17" }, { "id": "15593", "description": "Release 3.1.3", "name": "Release 3.1.3", "archived": true, "released": true, "releaseDate": "2013-09-18" }, { "id": "14982", "description": "Release 3.2.0", "name": "Release 3.2.0", "archived": false, "released": true, "releaseDate": "2013-12-19" } ], "issuelinks": [ { "id": "30463", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "outwardIssue": { "id": "117686", "key": "TIMOB-14691", "fields": { "summary": "iOS: ListView scrollToItem broken", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "priority": { "name": "Low", "id": "4" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } } ], "assignee": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "updated": "2014-02-18T10:33:15.000+0000", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "10206", "name": "iOS", "description": "iOS Platform" } ], "description": "*Problem*\r\nWhen using scrollToItem with larger lists, where the rows consist of more then 5 labels or views, scrolling starts only after a delay of approximately two seconds. This delay increases with the number of rows that have to be scrolled.\r\n\r\n*Steps to reproduce*\r\n1. Create a new Default Alloy Project and drop in the code below\r\n2. Run on iPhone 4 or equivalent device\r\n3. Tap Up/Down (anim)\r\n4. Observe that there is a delay before scrolling begins\r\n\r\n*listView.js*\r\n{code:javascript}\r\nvar myTemplate = {\r\n childTemplates: [\r\n { \r\n type: 'Ti.UI.Label',\r\n bindId: 'one', \r\n properties: { \r\n color: 'black',\r\n font: { fontFamily:'Arial', fontSize: '14dp' },\r\n left: '10dp'\r\n }\r\n },\r\n { \r\n type: 'Ti.UI.Label', \r\n bindId: 'two', \r\n properties: { \r\n color: 'black',\r\n font: { fontFamily:'Arial', fontSize: '14dp' },\r\n left: '50dp'\r\n }\r\n },\r\n { \r\n type: 'Ti.UI.Label', \r\n bindId: 'three', \r\n properties: { \r\n color: 'gray',\r\n font: { fontFamily:'Arial', fontSize: '14dp' },\r\n left: '90dp'\r\n }\r\n },\r\n { \r\n type: 'Ti.UI.Label', \r\n bindId: 'four', \r\n properties: { \r\n color: 'gray',\r\n font: { fontFamily:'Arial', fontSize: '14dp' },\r\n left: '130dp'\r\n }\r\n },\r\n { \r\n type: 'Ti.UI.Label', \r\n bindId: 'five', \r\n properties: { \r\n color: 'gray',\r\n font: { fontFamily:'Arial', fontSize: '14dp' },\r\n left: '170dp'\r\n }\r\n },\r\n { \r\n type: 'Ti.UI.Label', \r\n bindId: 'six', \r\n properties: { \r\n color: 'gray',\r\n font: { fontFamily:'Arial', fontSize: '14dp' },\r\n left: '210dp'\r\n }\r\n },\r\n { \r\n type: 'Ti.UI.Label', \r\n bindId: 'seven', \r\n properties: { \r\n color: 'gray',\r\n font: { fontFamily:'Arial', fontSize: '14dp' },\r\n left: '240dp'\r\n }\r\n }\r\n ]\r\n};\r\n \r\nvar upa = function() {\r\n $.list.scrollToItem(0, 0, {position: Titanium.UI.iPhone.TableViewScrollPosition.TOP}); \r\n}\r\n \r\nvar downa = function() {\r\n $.list.scrollToItem(3, 0, {position: Titanium.UI.iPhone.TableViewScrollPosition.TOP}); \r\n}\r\n \r\nvar up = function() {\r\n $.list.scrollToItem(0, 0, {animated: false, position: Titanium.UI.iPhone.TableViewScrollPosition.TOP}); \r\n}\r\n \r\nvar down = function() {\r\n $.list.scrollToItem(3, 0, {animated: false, position: Titanium.UI.iPhone.TableViewScrollPosition.TOP}); \r\n}\r\n \r\n \r\nvar genData = function(section) {\r\n var data = [];\r\n for(i=0;i<20;i++) {\r\n data.push({one:{text:section + ' one'}, two:{text: 'two'}, three:{text: 'three'}, four:{text: 'four'}, five:{text: 'five'}, six:{text: 'six'}, seven:{text: 'seven'}, template: 'template'})\r\n }\r\n \r\n return data;\r\n}\r\n \r\nvar genSections = function() {\r\n var sections = [];\r\n for(j=0;j<5;j++) {\r\n var section = Ti.UI.createListSection({headerTitle:'Section '+j});\r\n section.setItems(genData(j));\r\n sections.push(section);\r\n }\r\n \r\n return sections;\r\n}\r\n \r\nvar listView = $.list;\r\nlistView.templates = { 'template': myTemplate };\r\nlistView.setSections(genSections());\r\n\r\n$.index.open();\r\n{code}\r\n\r\n*index.xml*\r\n{code:xml}\r\n\r\n\t\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n{code}\r\n\r\n*index.tss*\r\n{code:css}\r\n\"#listView\": {\r\n backgroundColor: \"white\"\r\n}\r\n \r\n\"#list\" : {\r\n height: 420,\r\n top: 0\r\n}\r\n \r\n\"#buttons\": {\r\n backgroundColor: \"gray\",\r\n bottom:0,\r\n height:40,\r\n layout: 'horizontal'\r\n}\r\n{code}", "attachment": [], "flagged": false, "summary": "iOS: ListView: scrollToItem lags with large lists", "creator": { "name": "jcaff", "key": "jcaff", "displayName": "Joe Caff", "active": true, "timeZone": "Europe/Berlin" }, "subtasks": [], "reporter": { "name": "jcaff", "key": "jcaff", "displayName": "Joe Caff", "active": true, "timeZone": "Europe/Berlin" }, "environment": "TiSDK 3.1.3.GA\r\niPhone 4", "comment": { "comments": [ { "id": "258559", "author": { "name": "dsefton", "key": "dsefton", "displayName": "Daniel Sefton", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Tested and confirmed on iPhone 4 device, iOS 6 with Ti SDK 3.1.1 GA.", "updateAuthor": { "name": "dsefton", "key": "dsefton", "displayName": "Daniel Sefton", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-06-19T17:38:38.000+0000", "updated": "2013-06-19T17:38:38.000+0000" }, { "id": "263570", "author": { "name": "mokesmokes", "key": "mokesmokes", "displayName": "Mark Mokryn", "active": true, "timeZone": "Asia/Jerusalem" }, "updateAuthor": { "name": "mokesmokes", "key": "mokesmokes", "displayName": "Mark Mokryn", "active": true, "timeZone": "Asia/Jerusalem" }, "created": "2013-07-28T19:41:10.000+0000", "updated": "2013-07-28T19:41:10.000+0000" }, { "id": "285411", "author": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Pull pending against master\r\n\r\nhttps://github.com/appcelerator/titanium_mobile/pull/5156", "updateAuthor": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2013-12-20T19:42:38.000+0000", "updated": "2013-12-20T19:42:38.000+0000" }, { "id": "286576", "author": { "name": "mokesmokes", "key": "mokesmokes", "displayName": "Mark Mokryn", "active": true, "timeZone": "Asia/Jerusalem" }, "updateAuthor": { "name": "mokesmokes", "key": "mokesmokes", "displayName": "Mark Mokryn", "active": true, "timeZone": "Asia/Jerusalem" }, "created": "2014-01-03T09:44:00.000+0000", "updated": "2014-01-03T09:44:00.000+0000" }, { "id": "286600", "author": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Backport to 3_2_X\nhttps://github.com/appcelerator/titanium_mobile/pull/5181", "updateAuthor": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2014-01-03T18:17:56.000+0000", "updated": "2014-01-03T18:17:56.000+0000" }, { "id": "286928", "author": { "name": "pagarwal", "key": "pagarwal", "displayName": "Priya Agarwal", "active": true, "timeZone": "America/Los_Angeles" }, "body": "I too observed a time lag with 3.1.3.GA on iOS\nbut using \nTest Environment:\n\nAppc-Studio: 3.2.1.201401061716\nacs:1.0.11\nalloy:1.3.1-beta\nnpm:1.3.2\ntitanium:3.2.0\ntitanium-code-processor:1.1.0\nOsx: Maverick 10.9\nXcode: xCode 5.0.2\n\nusing both sdk build:3.2.1.v20140106195644 and 3.3.0.v20140106195650\n\nApp is working fine with above mentioned testCase\nNo more time lag. App runs smoothly\n", "updateAuthor": { "name": "pagarwal", "key": "pagarwal", "displayName": "Priya Agarwal", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2014-01-07T09:25:04.000+0000", "updated": "2014-01-07T09:25:04.000+0000" }, { "id": "287067", "author": { "name": "wluu", "key": "wluu", "displayName": "Wilson Luu", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Closing ticket as fixed. Verified the following:\r\n\r\n1. After pressing the Up/Down (anim) buttons, there is no initial delay before scrolling\r\n2. After pressing the Up/Down buttons (animated set to false), listview scrolls as expected i.e. no animation when scrolling\r\n3. Changed the genData function to generate 50 rows and was able to verify the above 2 test cases\r\n4. Used both the Alloy sample code and Titanium classic sample code to verify the above 3 test cases\r\n\r\nTested on:\r\n\r\nAppcelerator Studio, build: 3.2.1.201401061716\r\nSDK build: 3.2.1.v20140106195644, 3.3.0.v20140106195650\r\nCLI: 3.2.0\r\nAlloy: 1.3.1-beta\r\nXcode: 5.0.2\r\nDevices: iphone 4s (6.0.1), iphone 5s (7.0.2)\r\n\r\n*Note:* Was able to reproduce the original bug with SDK 3.2.0.GA as well.", "updateAuthor": { "name": "wluu", "key": "wluu", "displayName": "Wilson Luu", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2014-01-07T22:10:18.000+0000", "updated": "2014-01-07T22:11:51.000+0000" } ], "maxResults": 8, "total": 8, "startAt": 0 } } }