{ "id": "89940", "key": "TIMOB-8706", "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": "13271", "description": "Release 2.1.0", "name": "Release 2.1.0", "archived": false, "released": true, "releaseDate": "2012-06-29" }, { "id": "13405", "description": "Sprint 2012-09 API", "name": "Sprint 2012-09 API", "archived": true, "released": true, "releaseDate": "2012-05-06" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2012-07-10T05:00:56.000+0000", "created": "2012-04-12T15:56:25.000+0000", "priority": { "name": "High", "id": "2" }, "labels": [ "SupportTeam", "api", "module_tableview", "qe-testadded" ], "versions": [ { "id": "13271", "description": "Release 2.1.0", "name": "Release 2.1.0", "archived": false, "released": true, "releaseDate": "2012-06-29" }, { "id": "13070", "description": "Release 1.8 Service Pack 2", "name": "Release 1.8.2", "archived": true, "released": true, "releaseDate": "2012-02-29" } ], "issuelinks": [], "assignee": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "updated": "2013-12-10T06:13:00.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": "10202", "name": "Android", "description": "Android Platform" } ], "description": "h2. Problem description\r\ntableView 'scroll' event is triggered also when just opening the tableView, clicking on a row or opening the keyboard.\r\n\r\nh2. Steps to reproduce\r\n- Create a tableView and set an event listener associated to the 'scroll' event\r\nResult: function is called when opening the window, clicking on a row in the tableView and other events not relative to scroll (see code sample - also when clicking on a textField and opening the keyboard)\r\n\r\nSame code works as expected on iOS.\r\n\r\n{code:lang=javascript}\r\nvar win = Ti.UI.createWindow({\r\n\ttitle:'pippo',\r\n\tbackgroundColor:'gray'\r\n});\r\n\r\nvar search = Titanium.UI.createTextField({ \r\n\t// color:'#336699', \r\n\ttop:5,\r\n\twidth:400,\r\n\tleft:10, \r\n\thintText:'Search for ...',\r\n\tborderStyle:Titanium.UI.INPUT_BORDERSTYLE_ROUNDED, keyboardType:Titanium.UI.KEYBOARD_DEFAULT, returnKeyType:Titanium.UI.RETURNKEY_DEFAULT\r\n});\r\n\r\nwin.add(search);\r\n\r\nvar data = [];\r\nvar autocomplete_table = Titanium.UI.createTableView({ \r\n\tscrollable: true, \r\n\ttop: 170,\r\n\tbottom:0,\r\n\tbackgroundColor:'white',\r\n\tdata:data\r\n});\r\n\r\nvar row = Ti.UI.createTableViewRow({\r\n\ttitle:'test'\r\n});\r\ndata.push(row);\r\n\r\nvar autocomplete_table = Titanium.UI.createTableView({ \r\n\tscrollable: true, \r\n\ttop: 170,\r\n\tbottom:0,\r\n\tbackgroundColor:'white',\r\n\tdata:data\r\n});\r\n\r\n\r\nwin.add(autocomplete_table);\r\n\r\nautocomplete_table.addEventListener('scroll', function(e) { \r\n\tsearch.blur(); \r\n\talert('triggered!')\r\n});\r\n\r\nwin.open();\r\n\r\n{code}\r\n\r\n\r\nh2. Additional notes\r\nCustomer ticket associated: http://support-admin.appcelerator.com/display/APP-613444", "attachment": [], "flagged": false, "summary": "Android: TableView scroll event is also triggered for other events. ", "creator": { "name": "fcasali", "key": "fcasali", "displayName": "Federico Casali", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "fcasali", "key": "fcasali", "displayName": "Federico Casali", "active": true, "timeZone": "America/Los_Angeles" }, "environment": "Android OS\r\nTiSDK 1.8.2", "comment": { "comments": [ { "id": "192295", "author": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Test code\r\n{code}\r\nvar win = Ti.UI.createWindow({\r\n title:'pippo',\r\n backgroundColor:'gray'\r\n});\r\n \r\nvar search = Titanium.UI.createTextField({ \r\n // color:'#336699', \r\n top:5,\r\n width:400,\r\n left:10, \r\n hintText:'Search for ...',\r\n borderStyle:Titanium.UI.INPUT_BORDERSTYLE_ROUNDED, keyboardType:Titanium.UI.KEYBOARD_DEFAULT, returnKeyType:Titanium.UI.RETURNKEY_DEFAULT\r\n});\r\n \r\nwin.add(search);\r\n \r\nvar data = [];\r\nvar autocomplete_table = Titanium.UI.createTableView({ \r\n scrollable: true, \r\n top: 170,\r\n bottom:0,\r\n backgroundColor:'white',\r\n data:data\r\n});\r\n\r\nfor (i=0;i<50;i++)\r\n{ \r\n\tvar row = Ti.UI.createTableViewRow({\r\n \ttitle:'test' + i\r\n\t});\r\n\tdata.push(row);\r\n}\r\n \r\nvar autocomplete_table = Titanium.UI.createTableView({ \r\n scrollable: true, \r\n top: 170,\r\n bottom:0,\r\n backgroundColor:'white',\r\n data:data\r\n});\r\n \r\n \r\nwin.add(autocomplete_table);\r\n \r\nautocomplete_table.addEventListener('scroll', function(e) { \r\n search.blur(); \r\n Ti.API.info(\"scroll fired\");\r\n});\r\n \r\nwin.open();\r\n{code}", "updateAuthor": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2012-04-23T14:54:58.000+0000", "updated": "2012-04-23T14:54:58.000+0000" }, { "id": "192296", "author": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Pull pending https://github.com/appcelerator/titanium_mobile/pull/2052", "updateAuthor": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2012-04-23T14:57:35.000+0000", "updated": "2012-04-23T14:57:35.000+0000" }, { "id": "199910", "author": { "name": "psingh", "key": "psingh", "displayName": "Payminder Singh", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Titanium Studio: 2.1.0.201206221045 & 2.0.2\r\nMobile SDK: 2.1.0.v20120622174154\r\nOS: X Lion\r\nDevice: Samsung Galaxy \r\n\r\nCan't reproduce.\r\n\r\nScroll event get fired only by scrolling, tap on text area or on rows doen't fired scrolling event. ", "updateAuthor": { "name": "psingh", "key": "psingh", "displayName": "Payminder Singh", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-06-23T13:11:19.000+0000", "updated": "2012-06-23T13:11:19.000+0000" }, { "id": "202323", "author": { "name": "nchhabra", "key": "nchhabra", "displayName": "Neha Chhabra", "active": true, "timeZone": "Asia/Kolkata" }, "body": "Reopening to update labels.", "updateAuthor": { "name": "nchhabra", "key": "nchhabra", "displayName": "Neha Chhabra", "active": true, "timeZone": "Asia/Kolkata" }, "created": "2012-07-10T05:00:24.000+0000", "updated": "2012-07-10T05:00:24.000+0000" }, { "id": "283486", "author": { "name": "shameerj", "key": "shameerj", "displayName": "Shameer Jan", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Anvil testcase PR https://github.com/appcelerator/titanium_mobile/pull/5003\n", "updateAuthor": { "name": "shameerj", "key": "shameerj", "displayName": "Shameer Jan", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-12-10T06:13:00.000+0000", "updated": "2013-12-10T06:13:00.000+0000" } ], "maxResults": 6, "total": 6, "startAt": 0 } } }