سؤال

Can you tell me how to attach headerclick or headerdblclick event to Ext.grid.GridPanel?

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

المحلول

You can either use the listeners config (at config time) or the .on() method (with a grid reference).

{
    xtype: 'grid',
    listeners: {
        'headerclick': {
            fn: function(grid, col, e){
                // whatever
            },
            scope: this
         }
     }
 }

or

myGrid.on('headerclick', function(grid, col, e){
    // whatever
});
مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top