{ "id": "164491", "key": "TIMOB-24138", "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": "20115", "name": "Release 7.3.0", "archived": false, "released": true, "releaseDate": "2018-08-17" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2018-07-03T12:07:57.000+0000", "created": "2016-11-11T05:36:04.000+0000", "priority": { "name": "High", "id": "2" }, "labels": [ "TextArea", "TextField", "android", "focus", "parity" ], "versions": [], "issuelinks": [ { "id": "53463", "type": { "id": "10001", "name": "Cloners", "inward": "is cloned into", "outward": "is cloned from" }, "outwardIssue": { "id": "83074", "key": "TIMOB-6745", "fields": { "summary": "Android: UI - TextField's \"focus\" event is fired without user interaction", "status": { "description": "A resolution has been taken, and it is awaiting verification by reporter. From here issues are either reopened, or are closed.", "name": "Resolved", "id": "5", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "priority": { "name": "High", "id": "2" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } }, { "id": "56664", "type": { "id": "10001", "name": "Cloners", "inward": "is cloned into", "outward": "is cloned from" }, "inwardIssue": { "id": "171874", "key": "TIMOB-26178", "fields": { "summary": "Windows: TextField/TextArea should not receive focus by default when a window is opened", "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": "Medium", "id": "3" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } }, { "id": "56661", "type": { "id": "10002", "name": "Duplicate", "inward": "is duplicated by", "outward": "duplicates" }, "inwardIssue": { "id": "86456", "key": "TIMOB-8637", "fields": { "summary": "Android: auto-focuses and shows keyboard for first textfield on Samsung Galaxy Tab on window open or textfield create after window open", "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": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2018-07-03T21:40:28.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. Behavior\r\n\r\nIt seems that \"focus\" event doesn't work well on Android and this behavior cause awful user experience. To see the issue, run the test case below.\r\n\r\nScroll to the bottom, but don't touch text fields. You'll see in the console output that text field fired \"focus\" event and that keyboard has shown on the screen.\r\n\r\nAlso, scroll to the bottom, click \"Click me!\" button to open new window. Then, click \"Close me!\" button. ScrollView should be scrolled up to the text field that has \"focus\" (gained by a bug described above!), which creates awful user experience because user needs to scroll back to where he was before opening new window (ScrollView should not scroll after returning from newly created window).\r\n\r\nh2. Test case\r\n\r\n{code:lang=javascript|title=app.js}\r\nvar win = Ti.UI.createWindow({\r\n\tbackgroundColor: '#000',\r\n\tmodal: true,\r\n\tnavBarHidden: true,\r\n\tlayout: 'vertical'\r\n});\r\n\r\nfunction createItem() {\r\n\tvar view = Ti.UI.createView({\r\n\t\theight: 100,\r\n\t\twidth: '100%',\r\n\t\tlayout: 'horizontal'\r\n\t});\r\n\t\r\n\tvar label = Ti.UI.createLabel({\r\n\t\ttext: 'Testing ...',\r\n\t\twidth: '50%'\r\n\t});\r\n\t\r\n\tvar checkbox = Ti.UI.createSwitch({\r\n\t\tstyle: Ti.UI.Android.SWITCH_STYLE_CHECKBOX\r\n\t});\r\n\t\r\n\tview.add(label);\r\n\tview.add(checkbox);\r\n\t\r\n\treturn view;\r\n}\r\n\r\nfunction createTextField() {\r\n\t\r\n\tvar view = Ti.UI.createView({\r\n\t\theight: 100,\r\n\t\twidth: '100%',\r\n\t\tbackgroundColor: '#0ff',\r\n\t\tlayout: 'horizontal'\r\n\t});\r\n\t\r\n\tvar label = Ti.UI.createLabel({\r\n\t\ttext: 'Text field ...',\r\n\t\twidth: '50%'\r\n\t});\r\n\t\r\n\tvar textField = Ti.UI.createTextField({\r\n\t\twidth: '30%'\r\n\t});\r\n\t\r\n\ttextField.addEventListener('focus', function() {\r\n\t\tTi.API.info('Focus fired');\r\n\t});\r\n\t\r\n\tview.add(label);\r\n\tview.add(textField);\r\n\t\r\n\treturn view;\r\n}\r\n\r\nvar scrollView = Ti.UI.createScrollView({\r\n\tlayout: 'vertical',\r\n\tbackgroundColor: '#f00',\r\n\tshowVerticalScrollIndicator: true,\r\n\theight: '100%',\r\n\twidth: '100%',\r\n\tcontentHeight: 'auto',\r\n\tcontentWidth: 'auto',\r\n\ttop: 0\r\n});\r\n\r\nfor (var m = 0; m < 3; ++m) {\r\n\tfor (var i = 0; i < 20; ++i) {\r\n\t\tscrollView.add(createItem());\r\n\t}\r\n\tvar view = createTextField();\r\n\tscrollView.add(view);\r\n}\r\n\r\nfor (var j = 0; j < 20; ++j) {\r\n\tscrollView.add(createItem());\r\n}\r\n\r\nvar button = Ti.UI.createButton({ title: 'Click me!' });\r\n\r\nbutton.addEventListener('click', function() {\r\n\tvar context = Ti.UI.createWindow({\r\n\t\tbackgroundColor: '#000',\r\n\t\tmodal: true,\r\n\t\tnavBarHidden: true,\r\n\t\tlayout: 'vertical'\r\n\t});\r\n\t\r\n\tvar closeButton = Ti.UI.createButton({ title: 'Close me!' });\r\n\t\r\n\tcloseButton.addEventListener('click', function() {\r\n\t\tcontext.close();\r\n\t});\r\n\t\r\n\tcontext.add(closeButton);\r\n\t\r\n\tcontext.open();\r\n});\r\n\r\nscrollView.add(button);\r\n\r\nwin.add(scrollView);\r\n\r\nTi.API.info('App runnning ...');\r\n\r\nwin.open();\r\n{code}\r\n\r\n", "attachment": [], "flagged": false, "summary": "Android: TextField/TextArea should not receive focus by default when a window is opened", "creator": { "name": "goyalpankaj054@gmail.com", "key": "goyalpankaj054@gmail.com", "displayName": "Pankaj Goyal", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "goyalpankaj054@gmail.com", "key": "goyalpankaj054@gmail.com", "displayName": "Pankaj Goyal", "active": true, "timeZone": "America/Los_Angeles" }, "environment": "* Titanium SDK version: 1.7.6 (11/22/11 14:11 194e8e6...)\r\n* Android 3.1\r\n* Lenovo Thinkpad Tablet\r\n* Windows XP SP3", "closedSprints": [ { "id": 1045, "state": "closed", "name": "2018 Sprint 13 SDK", "startDate": "2018-06-17T20:47:13.621Z", "endDate": "2018-07-01T20:47:00.000Z", "completeDate": "2018-07-02T18:40:05.029Z", "originBoardId": 114 }, { "id": 1050, "state": "closed", "name": "2018 Sprint 14 SDK", "startDate": "2018-07-01T18:40:57.193Z", "endDate": "2018-07-15T18:40:00.000Z", "completeDate": "2018-07-16T03:27:08.720Z", "originBoardId": 114 } ], "comment": { "comments": [ { "id": "400761", "author": { "name": "goyalpankaj054@gmail.com", "key": "goyalpankaj054@gmail.com", "displayName": "Pankaj Goyal", "active": true, "timeZone": "America/Los_Angeles" }, "body": "We are getting same issue on Appc Latest SDK 5.5.1. Please look into this\r\n\r\nThanks\r\nPankaj Goyal", "updateAuthor": { "name": "goyalpankaj054@gmail.com", "key": "goyalpankaj054@gmail.com", "displayName": "Pankaj Goyal", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2016-11-11T05:36:53.000+0000", "updated": "2016-11-11T05:36:53.000+0000" }, { "id": "403605", "author": { "name": "macasfaj", "key": "macasfaj", "displayName": "Miguel Ángel Castaño", "active": true, "timeZone": "Europe/Berlin" }, "body": "Same issue on 5.5.1 and 6.0.", "updateAuthor": { "name": "macasfaj", "key": "macasfaj", "displayName": "Miguel Ángel Castaño", "active": true, "timeZone": "Europe/Berlin" }, "created": "2016-12-19T11:32:06.000+0000", "updated": "2016-12-19T11:32:06.000+0000" }, { "id": "438879", "author": { "name": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "body": "PR (master): https://github.com/appcelerator/titanium_mobile/pull/10145", "updateAuthor": { "name": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2018-06-30T03:27:55.000+0000", "updated": "2018-06-30T03:27:55.000+0000" }, { "id": "438881", "author": { "name": "michael", "key": "michael", "displayName": "Michael Gangolf", "active": true, "timeZone": "Europe/Berlin" }, "body": "Awesome! Means we finally don't need https://github.com/mpociot/TiAndroidAutofocus or show/hide workarounds on Android anymore!?", "updateAuthor": { "name": "michael", "key": "michael", "displayName": "Michael Gangolf", "active": true, "timeZone": "Europe/Berlin" }, "created": "2018-06-30T10:31:00.000+0000", "updated": "2018-06-30T10:31:00.000+0000" }, { "id": "438934", "author": { "name": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "body": "[~michael], correct! :)\r\nThis should provide a much better user experience now.", "updateAuthor": { "name": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2018-07-02T17:26:01.000+0000", "updated": "2018-07-02T17:26:01.000+0000" }, { "id": "438948", "author": { "name": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "body": "PR (7.3.x): https://github.com/appcelerator/titanium_mobile/pull/10149", "updateAuthor": { "name": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2018-07-02T22:18:09.000+0000", "updated": "2018-07-02T22:18:09.000+0000" }, { "id": "438991", "author": { "name": "lchoudhary", "key": "lchoudhary", "displayName": "Lokesh Choudhary", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Verified the fix with SDK 7.3.0.v20180703051211.\r\nClosing.\r\n\r\nStudio Ver: 5.1.0.201806291005\r\nSDK Ver: 7.3.0.v20180703051211\r\nOS Ver: 4.2.13\r\nXcode Ver: 7.0.4\r\nAppc NPM: 1.1.3\r\nAppc CLI: 10.13.5\r\nDaemon Ver: Xcode 9.4.1\r\nTi CLI Ver: 5.1.1\r\nAlloy Ver: 1.12.0\r\nNode Ver: 8.9.1\r\nNPM Ver: 5.5.1\r\nJava Ver: 10.0.1\r\nDevices: ⇨ google Nexus 5 --- Android 6.0.1\r\n ⇨ google Nexus 6P --- Android 8.1.0\r\nEmulator: ⇨ Android 4.1.2\r\n", "updateAuthor": { "name": "lchoudhary", "key": "lchoudhary", "displayName": "Lokesh Choudhary", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2018-07-03T21:40:22.000+0000", "updated": "2018-07-03T21:40:22.000+0000" } ], "maxResults": 8, "total": 8, "startAt": 0 } } }