View Full Version : Context Menu on TreePanel headers?

12 Nov 2010, 4:15 AM
Just wondering if it is possible to have a context menu (right click) on column headers? Or customising the default menu on columns?

If so, how do I go about it?

12 Nov 2010, 5:08 AM
TreePanel supports a contextmenu event which is fired when any tree node is right-clicked.


12 Nov 2010, 6:09 AM
how do I listen for that event? I am slightly confused about how I implement listeners?

Do i add a ...

Grid.on('contextmenu', function() { .....});

or do I add this to my column model? grid? tree?

contextmenu : function (...) { ......},

basically i struggle with knowing where to apply certain bits of code, even though I know what syntax to use.

Any help please?

13 Nov 2010, 7:02 AM
Are you using a TreeGrid component or just a TreePanel?