2012-03-29 81 views
1

这里使用Ext.Viewport时添加动画是我app.js:如何在煎茶触摸2

Ext.application({ 
    views: ['SignIn'], 

    launch: function() { 
     // Initialize the signin view 
     Ext.Viewport.add(Ext.create('MyApp.view.SignIn')); 
    } 
}); 

MyApp.view.SignIn,我想设置在Ext.Viewport另一种观点认为,所以我只写Ext.Viewport.setActiveItem(someview)

它运作良好。但是,如何在添加动画时添加动画呢?

回答

3

试试这个:

Ext.Viewport.animateActiveItem(someview) 
+0

哇。这工作!没有文档,并且不直观,但是很有效! – 2012-05-16 03:50:01

1

尝试

Ext.Viewport.animateActiveItem({xtype:'panelLogin'}, {type:'slide'});