{ "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.
\nWork 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.
(from [115a4af5af5d168f9b07832ae3e1993125f900b7])\n[#3220 state:fixed-in-qa] when creating light\nweight windows, use existing ActivityProxy
\nWhen 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...
(from [62eb136eb4ef9e4e6f0e260a295da565480169f4])\n[#3220 state:fixed-in-qa] when creating light\nweight windows, use existing ActivityProxy
\nWhen 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...
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.
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.
\nCan you have a look ASAP Opie? Thx.
\nTrace:
\nfyi broken in 1_6_X as well.
Simple fail case for the crash:
\napp.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
\nwin1.js:
\n\nTi.API.info('hi');
\n
(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...
(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...
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)