-
17 Jan 2012 9:01 AM #1
Unanswered: Retreive a Component or element initial state after an animation !
Unanswered: Retreive a Component or element initial state after an animation !
Hi all,
I am trying to add an animation on a button when I click on it. The animation Works but the button disappear after the animation.
To retrieve the intial button state, I try to set the "dynamic" property of the animation to "false", but it causes an error. On the otherhand I try to redo the layout of the parent component, and also try to save a copy of the button state to apply it after, but it's not working !
Does anyone knows what to do to not loose my "dear component" ?
Thank's in advance
Near
-
17 Jan 2012 9:04 AM #2Sencha - Senior Forum Manager
- Join Date
- Mar 2007
- Location
- St. Louis, MO
- Posts
- 33,657
- Vote Rating
- 435
- Answers
- 3109
What are you doing in the handler?
Mitchell Simoens @SenchaMitch
Sencha Inc, Senior Forum Manager
________________
http://www.JSONPLint.com - Source to lint your JSONP!
Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
https://github.com/mitchellsimoens
Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/
Need more help with your app? Hire Sencha Services services@sencha.com
Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is almost in print!
When posting code, please use BBCode's CODE tags.
-
18 Jan 2012 1:42 AM #3
I am doing this from a controler
Code:click: function(button, event, op){ var grid = Ext.getCmp('TContenus'); button.animate( { to:{ x: 0, y: 0 }, duration: 1000, easing: 'ease', /* this part is one of the thing I tried to make it appears after the animation: try to redo the grid parent layout ! */ listeners: { afteranimate: function(){ grid.doLayout(); } } } ); }
-
18 Jan 2012 7:40 AM #4
Another problem I am facing now of the same type, I think, I am facing now is a collapse and expand animation on a panel, to emphase an update. To do this I use the successively the collapse and the expand method. But the result I get is toggleCollapse behavior i-e the panel just collapse when it went from an expanded state, and expand in the other case.
Is it a timing problem ?
does any animation of this already exists ?
regards
near


Reply With Quote