[TIMOB-15400] Mobile Web: Animation system crashes with staggered animations
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | High |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2013-10-07T17:35:53.000+0000 |
Affected Version/s | Release 3.1.0 |
Fix Version/s | 2013 Sprint 21, 2013 Sprint 21 Tooling, Release 3.2.0 |
Components | MobileWeb |
Labels | module_animation, qe-closed-3.2.0, qe-manualtest |
Reporter | Bryan Hughes |
Assignee | Bryan Hughes |
Created | 2013-10-06T04:22:12.000+0000 |
Updated | 2014-08-07T20:56:06.000+0000 |
Description
The animation system crashes when there are two animations in play for one element and the first animation stops before the second one starts because the second one had a delay set.
/*global Ti*/
var win = Ti.UI.createWindow({
backgroundColor: '#fff'
}),
view = Ti.UI.createView({
backgroundColor: '#f00',
width: 100,
height: 100,
left: 200,
top: 200
});
win.add(view);
win.open();
require.on.once(view, 'postlayout', function () {
setTimeout(function () {
view.animate({
left: 300,
width: 100,
height: 100,
duration: 500
});
setTimeout(function () {
view.animate({
top: 300,
width: 100,
height: 100,
duration: 500,
delay: 200
});
}, 400);
}, 0);
});
PR: https://github.com/appcelerator/titanium_mobile/pull/4761
Above test code works fine with no crash. Verified fix on: SDK: 3.2.0.v20131024120843 CLI version : 3.2.0 OS : MAC OSX 10.8.4 Alloy : 1.2.2 Appcelerator Studio, build: 3.2.0.201310181700 XCode : 5