PDA

View Full Version : Trying for really smooth transition between portrait and landscape on an IPad



pkellner
4 Apr 2012, 6:43 PM
I'm wanting to have my app transition from portrait <> landscape really really smoothly (buttery smooth). I built a trivial app with the ST designer that has no javascript events programmed. I notice that when I rotate the IPad, there is some jumping. My question:

Does Sencha do transitions using JavaScript or is it all done in CSS? I thought I heard Ed say it was all CSS. If that is true, is it media queries that are taking care of the rotations?

Here is an example that shows the jumping. Try this on a tablet.

http://agelessemail.peterkellner.net/ST2UI_test/test/app.html

If senchatouch is using javascript to calculate changes, is it possible to have ST not do that and let me handle it myself with media queries? Will that get me buttery smooth?

thx

mitchellsimoens
5 Apr 2012, 5:17 AM
All layouts are CSS based so if you want width/height transistions then you can use -webkit-transition in your CSS.

pkellner
5 Apr 2012, 5:37 AM
does that mean that there are no javascript listeners changing things on rotations?

mitchellsimoens
5 Apr 2012, 5:40 AM
Ext.Viewport will fire the orientationchange or resize event. but the size will be set before therefor not allowing you to catch it to animate the sizing.