PDA

View Full Version : Ext.Window work bat Ext.panel not work/what i do no good?



koko2589
21 Jun 2009, 10:22 AM
this work very good


handler: function(){
var win = new Ext.Window({
title: 'Slide window',
width: 640,
height: 400,
closeAction: 'hide',
buttons: [{
text: 'Close',
handler: function(){
win.hide(Ext.getBody());
}
}],
animShow: function(){
this.el.slideIn('l', {duration: 1, callback: function(){
this.afterShow(true);
}, scope: this});
},
animHide: function(){
this.el.disableShadow();
this.el.slideOut('l', {duration: 1, callback: function(){
this.el.hide();
this.afterHide();
}, scope: this});
}
});
win.show(Ext.getBody());

}

this not work

handler: function(){
var win = new Ext.panel({
title: 'Slide window',
width: 640,
height: 400,
closeAction: 'hide',
buttons: [{
text: 'Close',
handler: function(){
win.hide(Ext.getBody());
}
}],
animShow: function(){
this.el.slideIn('l', {duration: 1, callback: function(){
this.afterShow(true);
}, scope: this});
},
animHide: function(){
this.el.disableShadow();
this.el.slideOut('l', {duration: 1, callback: function(){
this.el.hide();
this.afterHide();
}, scope: this});
}
});
win.show(Ext.getBody());





}

Animal
21 Jun 2009, 10:31 AM
So, are you seeing errors in Firebug?

koko2589
21 Jun 2009, 11:24 AM
So, are you seeing errors in Firebug?
yes

Ext.panel is not a constructor

http://up96.siz.co.il/up1/5et0dnewmhob.jpg

sven
21 Jun 2009, 11:39 AM
It is Panel and not panel

koko2589
21 Jun 2009, 11:11 PM
It is Panel and not panel
:-?