Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-15719] Height and width animations have side effects on Galaxy S3

GitHub Issuen/a
TypeBug
PriorityHigh
StatusClosed
ResolutionFixed
Resolution Date2014-01-22T22:22:10.000+0000
Affected Version/sRelease 3.2.0
Fix Version/s2014 Sprint 02, 2014 Sprint 02 API, Release 3.2.3, Release 3.3.0
ComponentsAndroid
Labelsmodule_animation, qe-testadded, regression
ReporterPing Wang
AssigneePing Wang
Created2013-11-14T20:16:07.000+0000
Updated2014-04-18T21:45:01.000+0000

Description

var main = Ti.UI.createWindow({ backgroundColor:'#000' });

var container = Ti.UI.createView({ height:300, width:300, backgroundColor:'#fff' });
main.add(container);

var shifty = Ti.UI.createView({ top:10, left:10, height:200, width:200, backgroundColor:'#ff0000' });
container.add(shifty);

var btn = Ti.UI.createButton({ title:'do it', height:50, width:100, bottom:10 });
btn.addEventListener('click', function() {
shifty.animate({ height:50, width:50, duration:1500 });
});
main.add(btn);

main.open();
Run the above test case on Samsung S3 (4.0.4) and click the button. Expected behavior: both height and width of the square animate to 25%. Actual behavior: see the attached screen shot in TIMOB-2373. If we turn on the hardware acceleration in tiapp.xml
android:hardwareAccelerated="true"
the animation will work fine. This bug only happens on 3.2.0 because in 3.2.0 we start using the new animation mechanism - [Property Animation](http://developer.android.com/guide/topics/graphics/prop-animation.html).

Comments

  1. Allen Yeung 2013-12-16

    [~ingo], Correct.. at this point, we do not know of a more graceful fix.
  2. Ping Wang 2014-01-16

    PR: https://github.com/appcelerator/titanium_mobile/pull/5226 For FR, please follow the testing steps in TIMOB-15951, TIMOB-16087, TIMOB-15719, TIMOB-2373, TIMOB-13536.
  3. Ping Wang 2014-01-23

    3_2_X PR: https://github.com/appcelerator/titanium_mobile/pull/5245
  4. Lokesh Choudhary 2014-03-21

    Verified the fix on samsung galaxy S3 running android 4.0.4 & it seems to be fixed. We do not see any side effects & the animations are smooth as expected. Environment: Appc Studio : 3.2.3.201403181115 Ti SDK : 3.2.3.v20140320130134 , 3.3.0.v20140319124903 Mac OSX : 10.8.5 Alloy : 1.3.1 CLI - 3.2.1

JSON Source