{ "id": "142359", "key": "TIMOB-18326", "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": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2015-01-28T19:54:30.000+0000", "created": "2015-01-06T20:58:42.000+0000", "priority": { "name": "High", "id": "2" }, "labels": [], "versions": [], "issuelinks": [], "assignee": { "name": "mlangston", "key": "mlangston", "displayName": "Matt Langston", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2017-03-22T22:48:05.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": "12642", "name": "Windows", "description": "Windows authoring support" } ], "description": "Parroting bug discovered by @garymathews in #23:\r\n\r\n> There's a bug with JSValue that prevents it's value being set from another context due to the 'new' context overwriting the one the JSValue was created with. Shouldn't we be retaining the context and just setting the value?\r\n\r\n*Example*\r\n{code}\r\nJavascript\r\nvar window = Ti.UI.createWindow();\r\n\r\nvar button = Ti.UI.createButton({\r\n top: 20,\r\n bottom: 20,\r\n width: 200,\r\n height: Ti.UI.SIZE\r\n})\r\n\r\n// Set the title\r\n// This doesn't crash because the text 'BUTTON' belongs to the same\r\n// context 'button' was created in\r\nbutton.title = 'BUTTON';\r\n\r\nbutton.addEventListener('click',\r\n function (e) {\r\n // This will cause a crash due to the context of 'CRASH!'\r\n // overwriting the context 'title' was created with\r\n // shouldn't we be retaining the original context?\r\n button.title = 'CRASH!';\r\n }\r\n);\r\n\r\nwindow.add(button);\r\n{code}", "attachment": [], "flagged": false, "summary": "Windows: JSValue context issue", "creator": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "environment": null, "closedSprints": [ { "id": 317, "state": "closed", "name": "2015 Sprint 02 Windows", "startDate": "2015-01-17T01:00:50.859Z", "endDate": "2015-01-31T01:00:00.000Z", "completeDate": "2015-01-30T23:07:52.735Z", "originBoardId": 144 } ], "comment": { "comments": [ { "id": "339822", "author": { "name": "kiguchi", "key": "kota", "displayName": "Kota Iguchi", "active": false, "timeZone": "America/Los_Angeles" }, "body": "This is a issue on HAL and fixed in https://github.com/appcelerator/HAL/pull/21, needs to be integrated in titanium_mobile_windows.", "updateAuthor": { "name": "kiguchi", "key": "kota", "displayName": "Kota Iguchi", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2015-01-20T01:16:57.000+0000", "updated": "2015-01-20T01:16:57.000+0000" }, { "id": "341006", "author": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "body": "Sounds like this should be fixed now.", "updateAuthor": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "created": "2015-01-28T19:54:30.000+0000", "updated": "2015-01-28T19:54:30.000+0000" }, { "id": "415166", "author": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Closing ticket as fixed.", "updateAuthor": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2017-03-22T22:48:05.000+0000", "updated": "2017-03-22T22:48:05.000+0000" } ], "maxResults": 3, "total": 3, "startAt": 0 } } }