سؤال

I know there is an Ext.Fx.Anim in Ext JS 4.0 and it is missing in Ext JS 3.4. Just wanted to know if there are any workarounds in getting some basic (say ease in) animation for a Component in Ext JS 3.4.

هل كانت مفيدة؟

المحلول

I'm assuming you want to do it for a component that is not in a managed layout. If that is true, you can animate the Ext.Element that wraps your content by calling Ext.Component.getEl()

var panel =  new Ext.Panel({html: 'My content'});
// Or any method defined in http://docs.sencha.com/ext-js/3-4/#!/api/Ext.Fx
panel.getEl().slideIn();      

نصائح أخرى

In 3.4, you have Ext.Fx class, which is applied, automatically by the framework, to Ext.Element. So, every element, by default, has the animation support. And with this, the methods that you see in Ext.Fx are also available on you element, like - highlight, fadeIn, slideIn, etc.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top