{ "id": "136389", "key": "TIMOB-17673", "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": null, "resolutiondate": null, "created": "2014-09-10T18:49:35.000+0000", "priority": { "name": "None", "id": "6" }, "labels": [], "versions": [], "issuelinks": [], "assignee": null, "updated": "2018-02-28T20:03:24.000+0000", "status": { "description": "The issue is open and ready for the assignee to start work on it.", "name": "Open", "id": "1", "statusCategory": { "id": 2, "key": "new", "colorName": "blue-gray", "name": "To Do" } }, "components": [ { "id": "10224", "name": "TiAPI", "description": "This component is used for cross-platform API work. Specifications are most likely to use this component." } ], "description": "If an animation is trying to change a property to what is already applied (e.g. view has width of 1px, animation is setting to 1px), then the completion event is immediately fired, ignoring the animation duration.\r\n\r\nTo see this in action, run the code below. You'll see that for the first animation you get the console output one time; 2 seconds later, a flurry of console items appear.\r\n\r\nThis is problematic, as if you assume the complete event will not fire until after the duration has elapsed, this could lead to circumstances which cripple a running application.\r\n\r\n{code:title=index.xml}\r\n\r\n\t\r\n\t\t\r\n\t\r\n\r\n{code}\r\n\r\n{code:title=index.tss}\r\n\"#win\": {\r\n\twidth: Ti.UI.FILL,\r\n\theight: Ti.UI.FILL,\r\n\tbackgroundColor: \"#000\"\r\n},\r\n\"#container\": {\r\n\twidth: Ti.UI.FILL,\r\n\theight: Ti.UI.FILL,\r\n\tbackgroundColor: \"#FFF\"\r\n}\r\n{code}\r\n\r\n{code:title=index.js}\r\nfunction animateView() {\r\n\tTi.API.error(\"Running animateView\");\r\n\t\r\n\tvar anim = Ti.UI.createAnimation({\r\n\t\twidth: 1,\r\n\t\tduration: 2000\r\n\t});\r\n\t\r\n\tanim.addEventListener(\"complete\", function() {\r\n\t\tgradient();\r\n\t});\r\n\t\r\n\t$.container.animate(anim);\r\n}\r\n\r\n$.win.addEventListener(\"open\", animateView);\r\n\r\n$.win.open();\r\n{code}", "attachment": [], "flagged": false, "summary": "Animation duration is ignored if property is same as currently applied", "creator": { "name": "matthewcongrove", "key": "matthewcongrove", "displayName": "Matthew Congrove", "active": true, "timeZone": "America/Chicago" }, "subtasks": [], "reporter": { "name": "matthewcongrove", "key": "matthewcongrove", "displayName": "Matthew Congrove", "active": true, "timeZone": "America/Chicago" }, "environment": "TiMob 3.3.0 and 3.2.3, iOS 7.X", "comment": { "comments": [], "maxResults": 0, "total": 0, "startAt": 0 } } }