{ "id": "100501", "key": "AC-3282", "fields": { "issuetype": { "id": "4", "description": "An improvement or enhancement to an existing feature or task.", "name": "Improvement", "subtask": false }, "project": { "id": "12217", "key": "AC", "name": "Appcelerator - INBOX", "projectCategory": { "id": "10000", "description": "", "name": "Customer Service" } }, "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2012-09-10T15:44:38.000+0000", "created": "2012-09-05T13:03:36.000+0000", "labels": [], "versions": [], "issuelinks": [], "assignee": { "name": "btran", "key": "btran", "displayName": "Betty Tran", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2016-03-08T07:57:42.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": "14548", "name": "Titanium SDK & CLI", "description": "Please enter tickets related to the MobileSDK here." } ], "description": "When the frame size is changed (which happens on orientation change) the Dashboard View will currently recreate all buttons. This causes them to be animated from the upper left corner of the parent view; they will also occasionally be laid out incorrectly. Instead, we should simply relayout the existing buttons so they animate smoothly to their new position. Here's a test case:\r\n\r\n{code:javascript}\r\nTitanium.UI.setBackgroundColor('#000');\r\nvar win1 = Titanium.UI.createWindow({ \r\n title:'Tab 1',\r\n backgroundColor:'#fff'\r\n});\r\n\r\nvar dash1 = Ti.UI.createDashboardView({\r\n columnCount: 4,\r\n rowCount: 4\r\n});\r\n\r\nvar items = [[], [], []];\r\n\r\nfor (var j = 0; j < 3; j++) {\r\n for (var i = 0; i < 20; i++) {\r\n var item = Ti.UI.createDashboardItem();\r\n item.add(Ti.UI.createLabel({\r\n text: \"item numba \" + i,\r\n borderColor: '#'+i+'0'+i+'000',\r\n borderWidth: 3,\r\n left: 0, right: 0,\r\n height: 50, width: 50\r\n }));\r\n items[j][i] = item;\r\n }\r\n}\r\n\r\ndash1.setData(items[0]);\r\n\r\nwin1.add(dash1);\r\n\r\nwin1.open();\r\n\r\nwin1.addEventListener('click', function (event) {\r\n dash1.stopEditing();\r\n});\r\n{code}\r\n\r\nA pull request is on the way.", "attachment": [], "flagged": false, "summary": "iOS: DashboardView: don't recreate items on frame change", "creator": { "name": "rfranknj", "key": "rfranknj", "displayName": "Russell Frank", "active": true, "timeZone": "America/New_York" }, "subtasks": [], "reporter": { "name": "rfranknj", "key": "rfranknj", "displayName": "Russell Frank", "active": true, "timeZone": "America/New_York" }, "environment": "Titanium Mobile SDK HEAD", "comment": { "comments": [ { "id": "217671", "author": { "name": "rfranknj", "key": "rfranknj", "displayName": "Russell Frank", "active": true, "timeZone": "America/New_York" }, "body": "Pull request opened on Github: [#2871|https://github.com/appcelerator/titanium_mobile/pull/2871]", "updateAuthor": { "name": "rfranknj", "key": "rfranknj", "displayName": "Russell Frank", "active": true, "timeZone": "America/New_York" }, "created": "2012-09-05T13:23:52.000+0000", "updated": "2012-09-05T13:23:52.000+0000" }, { "id": "286112", "author": { "name": "shossain", "key": "shossain", "displayName": "Shak Hossain", "active": false, "timeZone": "America/Los_Angeles" }, "body": "https://github.com/appcelerator/titanium_mobile/pull/2871 was merged.", "updateAuthor": { "name": "shossain", "key": "shossain", "displayName": "Shak Hossain", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2013-12-28T09:34:33.000+0000", "updated": "2013-12-28T09:34:33.000+0000" } ], "maxResults": 2, "total": 2, "startAt": 0 } } }