{ "id": "114910", "key": "TIMOB-13979", "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": "15499", "description": "2013 Sprint 13 API", "name": "2013 Sprint 13 API", "archived": true, "released": true, "releaseDate": "2013-07-01" }, { "id": "15111", "description": "2013 Sprint 13", "name": "2013 Sprint 13", "archived": true, "released": true, "releaseDate": "2013-07-01" } ], "resolution": { "id": "2", "description": "The problem described is an issue which will never be fixed.", "name": "Won't Fix" }, "resolutiondate": "2013-06-20T21:49:53.000+0000", "created": "2013-05-24T13:28:09.000+0000", "priority": { "name": "Low", "id": "4" }, "labels": [ "SupportTeam" ], "versions": [], "issuelinks": [ { "id": "29668", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "outwardIssue": { "id": "115607", "key": "TIMOB-14139", "fields": { "summary": "Android: Intent extra does not seem to be present if the app is using TabGroup", "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": "High", "id": "2" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } } ], "assignee": { "name": "hpham", "key": "hpham", "displayName": "Hieu Pham", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2017-03-20T18:05:01.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\nThe event 'resume' is not fired when the application is using TabGroup.\r\n\r\nh2. Steps to reproduce\r\n\r\nUse the following code:\r\n\r\n{code}\r\nvar tabGroup = Ti.UI.createTabGroup();\r\n\r\nvar win = Ti.UI.createWindow({\r\n backgroundColor: 'red'\r\n});\r\n\r\nvar tab = Ti.UI.createTab({\r\n window: win,\r\n title: 'Test'\r\n});\r\n\r\ntabGroup.addTab(tab);\r\ntabGroup.open();\r\n\r\ntabGroup.addEventListener('open',function(){\r\n\tTi.API.info(\"##### Adding resume listener #####\");\r\n var activity = Ti.Android.currentActivity;\r\n activity.addEventListener('resume', function(e) {\r\n \tTi.API.info(\"##### Resumed #####\");\r\n });\r\n});\r\n{code}\r\n\r\nThe resume listener is never fired (tested on Nexus 4). If I replace the tabgroup with a simple window, it works.", "attachment": [], "flagged": false, "summary": "Android: activity resume not fired when using TabGroup", "creator": { "name": "dcassenti", "key": "dcassenti", "displayName": "Davide Cassenti", "active": true, "timeZone": "Europe/Berlin" }, "subtasks": [], "reporter": { "name": "dcassenti", "key": "dcassenti", "displayName": "Davide Cassenti", "active": true, "timeZone": "Europe/Berlin" }, "environment": "Android 4.2\r\nSDK 3.0\r\nSDK 3.1", "comment": { "comments": [ { "id": "256422", "author": { "name": "dcassenti", "key": "dcassenti", "displayName": "Davide Cassenti", "active": true, "timeZone": "Europe/Berlin" }, "body": "The resume fires if the listener is added to tab.getActicity():\n\n~~~\ntabgroup.getActivity().addEventListener('resume', function(e) {\n // code here\n});\n~~~\n\nHowever, there seem to be a problem with the extra data. See TIMOB-14139", "updateAuthor": { "name": "dcassenti", "key": "dcassenti", "displayName": "Davide Cassenti", "active": true, "timeZone": "Europe/Berlin" }, "created": "2013-06-06T15:24:07.000+0000", "updated": "2013-06-06T15:24:07.000+0000" }, { "id": "258807", "author": { "name": "hpham", "key": "hpham", "displayName": "Hieu Pham", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Ti.Android.currentActivity isn't giving us the tabGroup activity, but the root activity instead. This is because Ti.Android.currentActivity will always return the first activity of the current context. Basically in our case, since there is only one context, currentActivity is set initially when the root activity is created. If you open a window using 'url', Ti.Android.currentActivity will change. Tabgroup.getActivity() should be used instead.", "updateAuthor": { "name": "hpham", "key": "hpham", "displayName": "Hieu Pham", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-06-20T20:37:12.000+0000", "updated": "2013-06-20T21:49:19.000+0000" }, { "id": "413860", "author": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Closing ticket as the issue will not fix.", "updateAuthor": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2017-03-20T18:05:01.000+0000", "updated": "2017-03-20T18:05:01.000+0000" } ], "maxResults": 5, "total": 5, "startAt": 0 } } }