{ "id": "61213", "key": "TIMOB-581", "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": "11242", "name": "Release 1.6.0 M09", "archived": true, "released": true, "releaseDate": "2011-02-14" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2011-04-17T01:53:34.000+0000", "created": "2011-04-15T02:32:25.000+0000", "priority": { "name": "Medium", "id": "3" }, "labels": [ "events", "ios", "release-1.6.0", "synthetic", "ui", "window" ], "versions": [], "issuelinks": [], "assignee": { "name": "rseagraves", "key": "rseagraves", "displayName": "Reggie Seagraves", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2011-04-17T01:53:34.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": "10206", "name": "iOS", "description": "iOS Platform" } ], "description": "{html}

The documentation for window suggests you can add an fire a\nsynthetic event for a window.

\n

See bottom of:
\n\nhttps://developer.appcelerator.com/apidoc/mobile/1.0/Titanium.UI.Wi...

\n

However, the following example app.js does not work:

\n

http://gist.github.com/335896

\n

The only synthetic events I've been able to successfully\nadd/fire have been global application ones\n(Ti.App.addEventListener...). This however, has its own\narchitectural issues namely, that you are now responsible for\ntearing it down yourself.

\n

Tested against iphone simulator.

{html}", "attachment": [], "flagged": false, "summary": "cannot add synthetic events to window", "creator": { "name": "noah", "key": "noah", "displayName": "Noah", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "noah", "key": "noah", "displayName": "Noah", "active": true, "timeZone": "America/Los_Angeles" }, "environment": null, "comment": { "comments": [ { "id": "123608", "author": { "name": "jaehess", "key": "jaehess", "displayName": "Jae Hess", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

+1 for this ticket

{html}", "updateAuthor": { "name": "jaehess", "key": "jaehess", "displayName": "Jae Hess", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:32:26.000+0000", "updated": "2011-04-15T02:32:26.000+0000" }, { "id": "123609", "author": { "name": "hal", "key": "hal", "displayName": "hal", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

This ticket has been duplicated at #536. I\npropose that #536 be closed, as #581 explains\nthe problem in more simple terms.

{html}", "updateAuthor": { "name": "hal", "key": "hal", "displayName": "hal", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:32:26.000+0000", "updated": "2011-04-15T02:32:26.000+0000" }, { "id": "123610", "author": { "name": "noah", "key": "noah", "displayName": "Noah", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Thanks for following up on this ticket. Enough time has passed\nthat I'm not certain whether or not this is an issue for more\ncurrent releases of titanium. If I recall correctly, my concern at\nthe time was there were cases where registering/deregistering a\nglobal event listener became non-trivial (a global event would\nregister itself twice and tearing it down involved adding another\nevent listener and a handle to the listener) whereas the\nconvenience of a window is that it manages its own lifecycle.

{html}", "updateAuthor": { "name": "noah", "key": "noah", "displayName": "Noah", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:32:26.000+0000", "updated": "2011-04-15T02:32:26.000+0000" }, { "id": "123611", "author": { "name": "hal", "key": "hal", "displayName": "hal", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Noah
\nYes, I agree, it would be a useful facility.
\nI can confirm that, for the latest build (dated 2nd Oct) on Android\nemulator at least, this bug still exists.

{html}", "updateAuthor": { "name": "hal", "key": "hal", "displayName": "hal", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:32:26.000+0000", "updated": "2011-04-15T02:32:26.000+0000" }, { "id": "123612", "author": { "name": "hal", "key": "hal", "displayName": "hal", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

See #2018 for the android ticket/fix

{html}", "updateAuthor": { "name": "hal", "key": "hal", "displayName": "hal", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:32:27.000+0000", "updated": "2011-04-15T02:32:27.000+0000" }, { "id": "123613", "author": { "name": "stephentramer", "key": "stephentramer", "displayName": "Stephen Tramer", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Tested against 1.6.0 RC1 for iOS. Checked test into\nbugtests.

{html}", "updateAuthor": { "name": "stephentramer", "key": "stephentramer", "displayName": "Stephen Tramer", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:32:27.000+0000", "updated": "2011-04-15T02:32:27.000+0000" }, { "id": "123614", "author": { "name": "jalter", "key": "jalter", "displayName": "Jon Alter", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Associated Helpdesk Ticket

\n

Waiting for docs
\nhttp://developer.appcelerator.com/helpdesk/view/76560

{html}", "updateAuthor": { "name": "jalter", "key": "jalter", "displayName": "Jon Alter", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:32:27.000+0000", "updated": "2011-04-15T02:32:27.000+0000" } ], "maxResults": 7, "total": 7, "startAt": 0 } } }