PDA

View Full Version : grid column headers mouseover event?



ttbgwt
24 Aug 2012, 10:09 AM
I'm trying to figure out how to listen to mouseover events for all of the column headers in a grid? I searched the docs and forums but came up empty...

vietits
24 Aug 2012, 4:32 PM
Try this:


Ext.create('Ext.grid.Panel', {
...
columns: {
items: [{
text: 'Column 1',
...
// listen mouseenter for specific column header
listeners: {
mouseenter: {
element: 'el',
fn: function(){
console.log('mouseenter column 1');
}
}
}
},{
...
}],
// listen mouseenter for all column headers
listeners: {
mouseenter: {
element: 'el',
fn: function(){
console.log('mouseenter');
}
}
}
}
});