{ "id": "148565", "key": "AC-1455", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "12217", "key": "AC", "name": "Appcelerator - INBOX", "projectCategory": { "id": "10000", "description": "", "name": "Customer Service" } }, "resolution": { "id": "5", "description": "All attempts at reproducing this issue failed, or not enough information was available to reproduce the issue. Reading the code produces no clues as to why this behavior would occur. If more information appears later, please reopen the issue.", "name": "Cannot Reproduce" }, "resolutiondate": "2015-07-21T20:27:39.000+0000", "created": "2015-06-08T12:37:32.000+0000", "labels": [ "android" ], "versions": [], "issuelinks": [], "assignee": { "name": "rtlechuga", "key": "rtlechuga", "displayName": "Radamantis Torres-Lechuga", "active": false, "timeZone": "Asia/Dubai" }, "updated": "2016-03-08T07:37:53.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": "h5. Environment\r\nOperating System\r\n Name = Mac OS X\r\n Version = 10.10.3\r\n\r\nNode.js\r\n Node.js Version = 0.12.1\r\n npm Version = 2.5.1\r\nTitanium CLI\r\n CLI Version = 3.4.2\r\nTitanium SDK\r\n SDK Version = 3.5.1.GA\r\n Target Platform = android\r\n\r\nh5. Example Code\r\n{code:js}\r\nvar templates = {\r\n slider :{\r\n childTemplates: [\r\n {\r\n type: 'Ti.UI.ImageView', \r\n allowsSelection: false,\r\n properties: { \r\n left: '10dp'\r\n }\r\n },\r\n {\r\n type: 'Ti.UI.Slider',\r\n events : {\r\n touchend : function(e) {\r\n var slider = e.source;\r\n\r\n slider.value = Number((slider.value).toFixed(0));\r\n }\r\n },\r\n\r\n properties: {\r\n width: 160,\r\n left : 100,\r\n paddingLeft: 10,\r\n min : 0,\r\n max : 2,\r\n value : 1\r\n }\r\n }\r\n ]\r\n }\r\n};\r\n\r\nvar listView = Ti.UI.createListView({\r\n top : 0,\r\n templates : templates,\r\n defaultItemTemplate : 'slider'\r\n});\r\n\r\nvar sections = [];\r\nvar section = Ti.UI.createListSection();\r\nvar items = [];\r\nsections.push(section);\r\n\r\nfor(var i = 0; i < 1; i ++) {\r\n console.warn('add ' + i);\r\n items.push({\r\n template : 'slider',\r\n bindID: '' + i\r\n });\r\n}\r\n\r\nsection.appendItems(items);\r\n\r\nlistView.sections = sections;\r\n\r\n$.win.add(listView);\r\n\r\n$.win.open();\r\n{code}\r\n\r\nh5. Expected behavior\r\nThe silder position snapp to the set position after the touch end\r\n\r\nh5. Current behavior\r\nThe silder doesn't move.", "attachment": [], "flagged": false, "summary": "Can't set position of a slider which is a child of a ListView", "creator": { "name": "c.waldmann@yatego.com", "key": "c.waldmann@yatego.com", "displayName": "Christian Waldmann", "active": true, "timeZone": "Europe/Berlin" }, "subtasks": [], "reporter": { "name": "c.waldmann@yatego.com", "key": "c.waldmann@yatego.com", "displayName": "Christian Waldmann", "active": true, "timeZone": "Europe/Berlin" }, "environment": "Android 4.4.4", "comment": { "comments": [ { "id": "354755", "author": { "name": "c.waldmann@yatego.com", "key": "c.waldmann@yatego.com", "displayName": "Christian Waldmann", "active": true, "timeZone": "Europe/Berlin" }, "body": "Same problem with 4.0.0.GA ", "updateAuthor": { "name": "c.waldmann@yatego.com", "key": "c.waldmann@yatego.com", "displayName": "Christian Waldmann", "active": true, "timeZone": "Europe/Berlin" }, "created": "2015-06-10T14:39:31.000+0000", "updated": "2015-06-10T14:39:31.000+0000" }, { "id": "356508", "author": { "name": "morahman", "key": "morahman", "displayName": "Motiur Rahman", "active": true, "timeZone": "Asia/Dhaka" }, "body": "Hello\r\n\r\nWe can set a position of a slider which is a child of listView. We did not get any unwanted behaviour. \r\n\r\n*Testing Environment*\r\nCLI: 4.0.2\r\nTi SDK: 4.0.0.GA,\r\nAndroid:4.4.4, 4.2.2, 5.0.1\r\n\r\n*Test Code*\r\n{code:title=app.js}\r\nvar win = Ti.UI.createWindow({\r\n\tbackgroundColor : 'white'\r\n});\r\nvar templates = {\r\n\tslider : {\r\n\t\tchildTemplates : [{\r\n\t\t\ttype : 'Ti.UI.ImageView',\r\n\t\t\tallowsSelection : false,\r\n\t\t\tproperties : {// Sets the ImageView.image property\r\n\t\t\t\tleft : 5,\r\n\t\t\t\timage : 'KS_nav_ui.png',\r\n\t\t\t\twidth : 50,\r\n\t\t\t\theight : 50\r\n\t\t\t}\r\n\t\t}, {\r\n\t\t\ttype : 'Ti.UI.Slider',\r\n\t\t\tevents : {\r\n\t\t\t\ttouchend : function(e) {\r\n\t\t\t\t\tvar slider = e.source;\r\n\r\n\t\t\t\t\tTi.API.info(Number((slider.value).toFixed(0)));\r\n\t\t\t\t}\r\n\t\t\t},\r\n\r\n\t\t\tproperties : {\r\n\t\t\t\twidth : 160,\r\n\t\t\t\tleft : 100,\r\n\t\t\t\tpaddingLeft : 10,\r\n\t\t\t\tmin : 0,\r\n\t\t\t\tmax : 100,\r\n\t\t\t\tvalue : 50\r\n\t\t\t}\r\n\t\t}]\r\n\t}\r\n};\r\n\r\nvar listView = Ti.UI.createListView({\r\n\ttop : 0,\r\n\ttemplates : templates,\r\n\tdefaultItemTemplate : 'slider'\r\n});\r\n\r\nvar sections = [];\r\nvar section = Ti.UI.createListSection();\r\nvar items = [];\r\nsections.push(section);\r\n\r\nfor (var i = 0; i < 10; i++) {\r\n\tconsole.warn('add ' + i);\r\n\titems.push({\r\n\t\ttemplate : 'slider',\r\n\t\tbindID : '' + i\r\n\t});\r\n}\r\n\r\nsection.appendItems(items);\r\n\r\nlistView.sections = sections;\r\n\r\nwin.add(listView);\r\n\r\nwin.open();\r\n\r\n\r\n\r\n{code}\r\n\r\nThanks.", "updateAuthor": { "name": "rtlechuga", "key": "rtlechuga", "displayName": "Radamantis Torres-Lechuga", "active": false, "timeZone": "Asia/Dubai" }, "created": "2015-07-01T07:17:07.000+0000", "updated": "2015-07-01T07:24:03.000+0000" } ], "maxResults": 2, "total": 2, "startAt": 0 } } }