{ "id": "63852", "key": "TIMOB-3220", "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": "11256", "description": "", "name": "Sprint-2011-08", "archived": true, "released": true, "releaseDate": "2011-02-28" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2011-04-17T02:01:13.000+0000", "created": "2011-04-15T03:39:46.000+0000", "priority": { "name": "Medium", "id": "3" }, "labels": [ "android", "defect", "listener", "release-1.6.1", "release-1.7.0", "reported-1.6.0", "window" ], "versions": [], "issuelinks": [], "assignee": { "name": "dthorp", "key": "dthorp", "displayName": "Don Thorp", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2011-04-17T02:01:13.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": "{html}

When a light weight window is opened, a new ActivityProxy is\ncreated rather than using the existing proxy for the activity. When\nsetting listeners in the new context for the window, events do not\nfire back to the correct proxy and cannot be handled.

\n

Work around is to open the new window as heavy weight or set the\nactivity listeners in the parent context where the activity was\ncreated. Example of the work around attached.

{html}", "attachment": [ { "id": "18283", "filename": "resources_lh.zip", "author": { "name": "opiecyrus", "key": "opiecyrus", "displayName": "Opie Cyrus", "active": true, "timeZone": "America/Chicago" }, "created": "2011-04-15T03:39:47.000+0000", "size": 825124, "mimeType": "application/zip" }, { "id": "18282", "filename": "resources.zip", "author": { "name": "opiecyrus", "key": "opiecyrus", "displayName": "Opie Cyrus", "active": true, "timeZone": "America/Chicago" }, "created": "2011-04-15T03:39:47.000+0000", "size": 825123, "mimeType": "application/zip" } ], "flagged": false, "summary": "Android: new ActivityProxy being created for light weight windows", "creator": { "name": "opiecyrus", "key": "opiecyrus", "displayName": "Opie Cyrus", "active": true, "timeZone": "America/Chicago" }, "subtasks": [], "reporter": { "name": "opiecyrus", "key": "opiecyrus", "displayName": "Opie Cyrus", "active": true, "timeZone": "America/Chicago" }, "environment": null, "comment": { "comments": [ { "id": "130319", "author": { "name": "opiecyrus", "key": "opiecyrus", "displayName": "Opie Cyrus", "active": true, "timeZone": "America/Chicago" }, "body": "{html}

(from [115a4af5af5d168f9b07832ae3e1993125f900b7])\n[#3220 state:fixed-in-qa] when creating light\nweight windows, use existing ActivityProxy

\n

When creating LW windows, use the existing ActivityProxy\nassociated Activity rather than creating a new ActivityProxy which\nwould cause activity listeners set on the new ActivityProxy to not\nfire correctly
\n\nhttps://github.com/appcelerator/titanium_mobile/commit/115a4af5af5d...

{html}", "updateAuthor": { "name": "opiecyrus", "key": "opiecyrus", "displayName": "Opie Cyrus", "active": true, "timeZone": "America/Chicago" }, "created": "2011-04-15T03:39:48.000+0000", "updated": "2011-04-15T03:39:48.000+0000" }, { "id": "130320", "author": { "name": "opiecyrus", "key": "opiecyrus", "displayName": "Opie Cyrus", "active": true, "timeZone": "America/Chicago" }, "body": "{html}

(from [62eb136eb4ef9e4e6f0e260a295da565480169f4])\n[#3220 state:fixed-in-qa] when creating light\nweight windows, use existing ActivityProxy

\n

When creating LW windows, use the existing ActivityProxy\nassociated Activity rather than creating a new ActivityProxy which\nwould cause activity listeners set on the new ActivityProxy to not\nfire correctly
\n\nhttps://github.com/appcelerator/titanium_mobile/commit/62eb136eb4ef...

{html}", "updateAuthor": { "name": "opiecyrus", "key": "opiecyrus", "displayName": "Opie Cyrus", "active": true, "timeZone": "America/Chicago" }, "created": "2011-04-15T03:39:48.000+0000", "updated": "2011-04-15T03:39:48.000+0000" }, { "id": "130321", "author": { "name": "opiecyrus", "key": "opiecyrus", "displayName": "Opie Cyrus", "active": true, "timeZone": "America/Chicago" }, "body": "{html}

I have attached the resources directory for a test to this\nissue. Upon opening the window, you should see the resume, pause,\ndestroy events handled in the log.

{html}", "updateAuthor": { "name": "opiecyrus", "key": "opiecyrus", "displayName": "Opie Cyrus", "active": true, "timeZone": "America/Chicago" }, "created": "2011-04-15T03:39:48.000+0000", "updated": "2011-04-15T03:39:48.000+0000" }, { "id": "130322", "author": { "name": "billdawson", "key": "billdawson", "displayName": "Bill Dawson", "active": true, "timeZone": "Europe/Berlin" }, "body": "{html}

Uh oh, this seems to have broken KitchenSink. KS crashes\nimmediately upon launching now, and I've traced it to this commit\n115a4af5af5d (I'm talking about the master branch here.) KS works\nfine with the commit before that.

\n

Can you have a look ASAP Opie? Thx.

\n

Trace:

\n

http://pastie.org/1617608

{html}", "updateAuthor": { "name": "billdawson", "key": "billdawson", "displayName": "Bill Dawson", "active": true, "timeZone": "Europe/Berlin" }, "created": "2011-04-15T03:39:49.000+0000", "updated": "2011-04-15T03:39:49.000+0000" }, { "id": "130323", "author": { "name": "billdawson", "key": "billdawson", "displayName": "Bill Dawson", "active": true, "timeZone": "Europe/Berlin" }, "body": "{html}

fyi broken in 1_6_X as well.

{html}", "updateAuthor": { "name": "billdawson", "key": "billdawson", "displayName": "Bill Dawson", "active": true, "timeZone": "Europe/Berlin" }, "created": "2011-04-15T03:39:49.000+0000", "updated": "2011-04-15T03:39:49.000+0000" }, { "id": "130324", "author": { "name": "billdawson", "key": "billdawson", "displayName": "Bill Dawson", "active": true, "timeZone": "Europe/Berlin" }, "body": "{html}

Simple fail case for the crash:

\n

app.js:

\n
\nTitanium.UI.setBackgroundColor('#000');\nvar tabGroup = Titanium.UI.createTabGroup();\nvar win1 = Titanium.UI.createWindow({  \n    title:'Tab 1', backgroundColor:'#fff', url: 'win1.js'\n});\nvar tab1 = Titanium.UI.createTab({  \n    title:'Tab 1', window:win1\n});\ntabGroup.addTab(tab1);  \ntabGroup.open();\n
\n

win1.js:

\n
\nTi.API.info('hi');\n
{html}", "updateAuthor": { "name": "billdawson", "key": "billdawson", "displayName": "Bill Dawson", "active": true, "timeZone": "Europe/Berlin" }, "created": "2011-04-15T03:39:49.000+0000", "updated": "2011-04-15T03:39:49.000+0000" }, { "id": "130325", "author": { "name": "billdawson", "key": "billdawson", "displayName": "Bill Dawson", "active": true, "timeZone": "Europe/Berlin" }, "body": "{html}

(from [7b91bba6d4625743452c391adb05b3254d7ff7ce])\nMake sure activityProxy gets filled also for tab windows with urls\n[#3220 state:fixed-in-qa] \nhttps://github.com/appcelerator/titanium_mobile/commit/7b91bba6d462...

{html}", "updateAuthor": { "name": "billdawson", "key": "billdawson", "displayName": "Bill Dawson", "active": true, "timeZone": "Europe/Berlin" }, "created": "2011-04-15T03:39:49.000+0000", "updated": "2011-04-15T03:39:49.000+0000" }, { "id": "130326", "author": { "name": "billdawson", "key": "billdawson", "displayName": "Bill Dawson", "active": true, "timeZone": "Europe/Berlin" }, "body": "{html}

(from [671a39a2c51f6fe389bab2815258f59eac31b32d])\nMake sure activityProxy gets filled also for tab windows with urls\n[#3220 state:fixed-in-qa] \nhttps://github.com/appcelerator/titanium_mobile/commit/671a39a2c51f...

{html}", "updateAuthor": { "name": "billdawson", "key": "billdawson", "displayName": "Bill Dawson", "active": true, "timeZone": "Europe/Berlin" }, "created": "2011-04-15T03:39:49.000+0000", "updated": "2011-04-15T03:39:49.000+0000" }, { "id": "130327", "author": { "name": "nhuynh", "key": "nhuynh", "displayName": "Natalie Huynh", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Tested with Titanium SDK version: 1.7.0 (03/02/11 13:57 5d8c78a)\non
\nGalaxy Tab 2.2
\nEmulator 2.1
\n(Test specific to Android only)

{html}", "updateAuthor": { "name": "nhuynh", "key": "nhuynh", "displayName": "Natalie Huynh", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T03:39:50.000+0000", "updated": "2011-04-15T03:39:50.000+0000" } ], "maxResults": 9, "total": 9, "startAt": 0 } } }