{ "id": "98397", "key": "TIMOB-10304", "fields": { "issuetype": { "id": "2", "description": "A new feature of the product, which has yet to be developed.", "name": "New Feature", "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": "2012-07-31T02:14:15.000+0000", "priority": { "name": "Low", "id": "4" }, "labels": [ "core", "insight" ], "versions": [ { "id": "13505", "description": "Release 3.0.0", "name": "Release 3.0.0", "archived": true, "released": true, "releaseDate": "2012-12-14" } ], "issuelinks": [], "assignee": null, "updated": "2018-02-28T20:03:49.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": "10202", "name": "Android", "description": "Android Platform" } ], "description": "i needed to have a way to cancel running animations on a view.\r\nSo i added cancelAllAnimations\r\ntest case:\r\n{code}\r\nvar win = Ti.UI.createWindow({ fullscreen: true, backgroundColor: 'white'});\r\n \r\nvar view = Ti.UI.createView({\r\n backgroundColor:'red',\r\n height:100,\r\n width:100,\r\n top:0,\r\n left:0\r\n});\r\nwin.add(view);\r\n\r\nvar button = Titanium.UI.createButton({\r\n title:'Animate',\r\n width:200,\r\n height:40,\r\n bottom:20,\r\n left: 10\r\n});\r\n\r\nbutton.addEventListener('click', function()\r\n{\r\n view.updateLayout({left:0});\r\n view.left = 0;\r\n view.animate({left:(win.rect.width - view.rect.width), duration:2000}, function(){alert('animation completed!');});\r\n});\r\nwin.add(button);\r\n\r\nbutton = Titanium.UI.createButton({\r\n title:'Cancel Animations',\r\n width:200,\r\n height:40,\r\n bottom:20,\r\n right:10\r\n});\r\nbutton.addEventListener('click', function()\r\n{\r\n view.cancelAllAnimations();\r\n});\r\nwin.add(button);\r\n\r\nwin.open();\r\n{code}", "attachment": [], "flagged": false, "summary": "Android: Cancel running animations on a view", "creator": { "name": "farfromrefuge", "key": "farfromrefuge", "displayName": "Martin Guillon", "active": false, "timeZone": "Europe/Berlin" }, "subtasks": [], "reporter": { "name": "farfromrefuge", "key": "farfromrefuge", "displayName": "Martin Guillon", "active": false, "timeZone": "Europe/Berlin" }, "environment": "Titanium 2.2.0 (master)\r\nios 5.1\r\nandroid 3.2", "comment": { "comments": [], "maxResults": 0, "total": 0, "startAt": 0 } } }