PDA

View Full Version : Handler for when the window body is clicked



koko2589
31 Oct 2011, 1:40 PM
how to hide the panel when clicked
itry

handleClick: function (event) {
this.fireEvent('click', this);panel.hide();
},

not work
tankyou

koko2589
31 Oct 2011, 2:03 PM
ok its work

listeners: {
render: function(c){
c.getEl().on({
click: function(el){
panel.hide();
},
scope: c
});
}

},:))

skirtle
1 Nov 2011, 6:25 AM
Please use [CODE] tags when posting code.

Maybe this is a little simpler?


listeners: {
el: {
click: function() {
panel.hide();
}
}
}