{ "id": "148203", "key": "TIMOB-18951", "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": "16723", "description": "Windows Platform Support, ListView updates, Vector overlays in maps", "name": "Release 4.1.0", "archived": false, "released": true, "releaseDate": "2015-07-08" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2015-06-11T03:07:51.000+0000", "created": "2015-05-26T09:51:08.000+0000", "priority": { "name": "High", "id": "2" }, "labels": [ "picker", "touchEnabled" ], "versions": [ { "id": "16711", "description": "Release 3.5.1", "name": "Release 3.5.1", "archived": false, "released": true, "releaseDate": "2015-03-06" }, { "id": "16593", "description": "Release 4.0.0", "name": "Release 4.0.0", "archived": false, "released": true, "releaseDate": "2015-05-21" } ], "issuelinks": [], "assignee": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "updated": "2015-06-17T18:46:16.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": "Setting {{touchEnabled}} to {{false}} causes the app to crash on Android:\r\n\r\nh3. Reproducing code\r\n\r\n{code:xml}\r\n\r\n\t\r\n\t\t\r\n\t\r\n\r\n{code}\r\n\r\nh3. Log\r\n\r\n{code}\r\n[ERROR] : TiApplication: (main) [558,558] Sending event: exception on thread: main msg:java.lang.RuntimeException: Unable to start activity ComponentInfo{com.reynald.test4project/org.appcelerator.titanium.TiActivity}: java.lang.RuntimeException: Don't call setOnClickListener for an AdapterView. You probably want setOnItemClickListener instead; Titanium 4.0.0,2015/05/18 15:42,9239ff9\r\n[ERROR] : TiApplication: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.reynald.test4project/org.appcelerator.titanium.TiActivity}: java.lang.RuntimeException: Don't call setOnClickListener for an AdapterView. You probably want setOnItemClickListener instead\r\n[ERROR] : TiApplication: at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2059)\r\n[ERROR] : TiApplication: at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2084)\r\n[ERROR] : TiApplication: at android.app.ActivityThread.access$600(ActivityThread.java:130)\r\n[ERROR] : TiApplication: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1195)\r\n[ERROR] : TiApplication: at android.os.Handler.dispatchMessage(Handler.java:99)\r\n[ERROR] : TiApplication: at android.os.Looper.loop(Looper.java:137)\r\n[ERROR] : TiApplication: at android.app.ActivityThread.main(ActivityThread.java:4745)\r\n[ERROR] : TiApplication: at java.lang.reflect.Method.invokeNative(Native Method)\r\n[ERROR] : TiApplication: at java.lang.reflect.Method.invoke(Method.java:511)\r\n[ERROR] : TiApplication: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:786)\r\n[ERROR] : TiApplication: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:553)\r\n[ERROR] : TiApplication: at dalvik.system.NativeStart.main(Native Method)\r\n[ERROR] : TiApplication: Caused by: java.lang.RuntimeException: Don't call setOnClickListener for an AdapterView. You probably want setOnItemClickListener instead\r\n{code}\r\n\r\nReported via Q&A:\r\nhttps://community.appcelerator.com/topic/520/app-crashed-when-using-widget-with-picker-in-it/3", "attachment": [], "flagged": false, "summary": "Android: Setting Picker.touchEnabled (to false) crashes", "creator": { "name": "fokkezb", "key": "fokke", "displayName": "Fokke Zandbergen", "active": true, "timeZone": "Europe/Amsterdam" }, "subtasks": [], "reporter": { "name": "fokkezb", "key": "fokke", "displayName": "Fokke Zandbergen", "active": true, "timeZone": "Europe/Amsterdam" }, "environment": "Reproduced with 3.5.1.GA and 4.0.0.GA", "closedSprints": [ { "id": 416, "state": "closed", "name": "2015 Sprint 12 SDK", "startDate": "2015-06-06T00:00:43.862Z", "endDate": "2015-06-20T00:00:00.000Z", "completeDate": "2015-06-23T05:41:35.834Z", "originBoardId": 114 } ], "comment": { "comments": [ { "id": "354648", "author": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "body": "PR: https://github.com/appcelerator/titanium_mobile/pull/6900\r\n\r\nTo test, scons and follow instructions above in alloy.", "updateAuthor": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "created": "2015-06-09T06:48:18.000+0000", "updated": "2015-06-09T06:48:18.000+0000" }, { "id": "354701", "author": { "name": "hpham", "key": "hpham", "displayName": "Hieu Pham", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Titanium test case:\r\n{code}\r\nTi.UI.backgroundColor = 'white';\r\nvar win = Ti.UI.createWindow({\r\n exitOnClose: true,\r\n layout: 'vertical'\r\n});\r\n\r\nvar picker = Ti.UI.createPicker({\r\n top:50,\r\n touchEnabled: false\r\n});\r\n\r\nvar data = [];\r\ndata[0]=Ti.UI.createPickerRow({title:'Bananas'});\r\ndata[1]=Ti.UI.createPickerRow({title:'Strawberries'});\r\ndata[2]=Ti.UI.createPickerRow({title:'Mangos'});\r\ndata[3]=Ti.UI.createPickerRow({title:'Grapes'});\r\n\r\npicker.add(data);\r\npicker.selectionIndicator = true;\r\n\r\nwin.add(picker);\r\nwin.open();\r\n\r\n// must be after picker has been displayed\r\npicker.setSelectedRow(0, 2, false); // select Mangos\r\n{code}", "updateAuthor": { "name": "hpham", "key": "hpham", "displayName": "Hieu Pham", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2015-06-09T21:36:41.000+0000", "updated": "2015-06-09T21:36:41.000+0000" }, { "id": "354840", "author": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "body": "Marking this as resolved as PR has been reviewed and merged.", "updateAuthor": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "created": "2015-06-11T03:07:42.000+0000", "updated": "2015-06-11T03:07:42.000+0000" }, { "id": "355289", "author": { "name": "lchoudhary", "key": "lchoudhary", "displayName": "Lokesh Choudhary", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Verified the fix.\r\n\r\nSetting touchEnabled to false does not crash the app.\r\n\r\nClosing\r\n\r\nEnvironment:\r\nAppc Studio : 4.1.0.201506151224\r\nTi SDK : 4.1.0.v20150614181235\r\nTi CLI : 4.0.1\r\nAlloy : 1.6.2\r\nMAC Yosemite : 10.10.3\r\nAppc npm : 4.0.1\r\nAppc CLI : 4.0.2\r\nNode: v0.10.37\r\nAndroid 5.0.2", "updateAuthor": { "name": "lchoudhary", "key": "lchoudhary", "displayName": "Lokesh Choudhary", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2015-06-16T23:45:20.000+0000", "updated": "2015-06-17T18:46:08.000+0000" } ], "maxResults": 4, "total": 4, "startAt": 0 } } }