{ "id": "93063", "key": "TIMOB-9488", "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": [], "resolution": { "id": "2", "description": "The problem described is an issue which will never be fixed.", "name": "Won't Fix" }, "resolutiondate": "2018-04-04T23:57:42.000+0000", "created": "2012-06-11T15:38:20.000+0000", "priority": { "name": "Low", "id": "4" }, "labels": [ "SupportTeam", "parity" ], "versions": [ { "id": "13271", "description": "Release 2.1.0", "name": "Release 2.1.0", "archived": false, "released": true, "releaseDate": "2012-06-29" }, { "id": "14982", "description": "Release 3.2.0", "name": "Release 3.2.0", "archived": false, "released": true, "releaseDate": "2013-12-19" } ], "issuelinks": [], "assignee": { "name": "cbarber", "key": "cbarber", "displayName": "Chris Barber", "active": true, "timeZone": "America/Chicago" }, "updated": "2018-04-05T00:00:03.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": "11500", "name": "MobileWeb", "description": "Mobile Web (HTML) Platform" } ], "description": "h4. Problem Description\r\nTabgroup's focus event is not working as with iOS. \r\n\r\nh4. Actual Results\r\nThe focus event is never fired \r\n\r\nh4. Expected results\r\nThe focus event should fire.\r\n\r\nh4. Testcase\r\n1. Create new mobile Project.\r\n2. Paste app.js:\r\n{code}\r\nTitanium.UI.setBackgroundColor('#000');\r\n\r\n// create tab group\r\nvar tabGroup = Titanium.UI.createTabGroup();\r\nvar win = Titanium.UI.createWindow({\r\n backgroundColor:'white',\r\n title:'window',\r\n barColor:'#ff7b01',\r\n top:0,\r\n navBarHidden:false\r\n });\r\n \r\n/* win.addEventListener('focus',function(){\r\n\talert('focus');\r\n}); */\r\n var tab1 = Titanium.UI.createTab({ \r\n icon:'KS_nav_views.png',\r\n title:'Tab 1',\r\n window:win\r\n}); \r\n var tab2 = Titanium.UI.createTab({ \r\n icon:'KS_nav_views.png',\r\n title:'Tab 2',\r\n window:win\r\n}); \r\n var titleImage = Ti.UI.createView({\r\n\t\t\t\t\t\t\twidth:94,\r\n\t\t\t\t\t\t\theight:24,\r\n\t\t\t\t\t\t\tbackgroundImage:'/images/header/ing_logo_header.png',\r\n\t\t\t\t\t\t});\r\n\t\t\t\t\t\twin.titleControl = titleImage;\r\n\t\t\t\t\t\t\r\n//win.open();\r\ntabGroup.addTab(tab1); \r\ntabGroup.addTab(tab2);\r\ntabGroup.open();\r\ntabGroup.addEventListener('focus',function(){\r\n\talert('focus tabs fired')\r\n});\r\ntabGroup.addEventListener('click',function(){\r\n\talert('click fired')\r\n});\r\n{code}\r\n3. Test this code in iOS, compare with this code in MobileWeb.\r\n\r\n", "attachment": [], "flagged": false, "summary": "MobileWeb: Focus event in tabgroup not being fired", "creator": { "name": "mpmiranda", "key": "mpmiranda", "displayName": "Mauro Parra-Miranda", "active": true, "timeZone": "America/Mexico_City" }, "subtasks": [], "reporter": { "name": "mpmiranda", "key": "mpmiranda", "displayName": "Mauro Parra-Miranda", "active": true, "timeZone": "America/Mexico_City" }, "environment": "Titanium SDK version: 2.1.0.v20120607\r\nPlatform & version: Mobile Web, Chrome, Mac OSX \r\nDevice Details: Mobile Web, Chrome, Mac OSX \r\nHost Operating System: OSX 10.7.3 \r\nTitanium Studio version: 2.0.2", "closedSprints": [ { "id": 199, "state": "closed", "name": "2014 Sprint 18 SDK", "startDate": "2014-09-02T22:56:57.421Z", "endDate": "2014-09-13T00:00:00.000Z", "completeDate": "2014-09-15T20:08:19.146Z", "originBoardId": 114 } ], "comment": { "comments": [ { "id": "198106", "author": { "name": "cbarber", "key": "cbarber", "displayName": "Chris Barber", "active": true, "timeZone": "America/Chicago" }, "body": "Mobile Web does not blur and re-focus the TabGroup when you change a tab because Mobile Web does not bubble events like iOS. Frankly, blurring and re-focusing the TabGroup when a tab is switched is pointless. Use the \"focus\" event on a TabGroup to know when a window is closed and the TabGroup regains focus. Use the \"click\" event on TabGroup to know when a tab has changed. Listen on a specific Tab to know when that Tab is clicked, focused, or blurred.", "updateAuthor": { "name": "cbarber", "key": "cbarber", "displayName": "Chris Barber", "active": true, "timeZone": "America/Chicago" }, "created": "2012-06-11T17:11:43.000+0000", "updated": "2012-06-11T17:11:43.000+0000" }, { "id": "198215", "author": { "name": "cbarber", "key": "cbarber", "displayName": "Chris Barber", "active": true, "timeZone": "America/Chicago" }, "body": "I fixed events on TabGroups and Tabs in TIMOB-9176. The focus event for a TabGroup is fired either when the TabGroup is opened or when a Window is closed and the TabGroup regains focus.\r\n\r\nThe TabGroup should not blur and re-focus every time you change tabs. That's a bug with iOS and Android. I'm working with Josh from the Android team to come up with a consensus with this.\r\n\r\nAs of right now, Mobile Web's implementation is not bound to change for v2.1.", "updateAuthor": { "name": "cbarber", "key": "cbarber", "displayName": "Chris Barber", "active": true, "timeZone": "America/Chicago" }, "created": "2012-06-12T13:53:35.000+0000", "updated": "2012-06-12T13:53:35.000+0000" }, { "id": "436496", "author": { "name": "emerriman", "key": "emerriman", "displayName": "Eric Merriman ", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Closing as will not fix\r\n", "updateAuthor": { "name": "emerriman", "key": "emerriman", "displayName": "Eric Merriman ", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2018-04-04T23:57:42.000+0000", "updated": "2018-04-04T23:57:42.000+0000" }, { "id": "436501", "author": { "name": "emerriman", "key": "emerriman", "displayName": "Eric Merriman ", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Closing as will not fix", "updateAuthor": { "name": "emerriman", "key": "emerriman", "displayName": "Eric Merriman ", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2018-04-05T00:00:03.000+0000", "updated": "2018-04-05T00:00:03.000+0000" } ], "maxResults": 7, "total": 7, "startAt": 0 } } }