Grid header click listener

Hi everyone,

I’m using grid with BeanContainer to display data which came from DB. I’d like to add somehow a header click listener, which is able to show a context menu when the user clicked with right button on the header, and reorder the table when the user clicked with left button. Is there any possible way to make a column header click listener like this?

I found only the SortListener, which reacts when a header is clicked, but the SortEvent does not contain any information about which button was clicked.

Have you any idea to solve this problem?

Thanks for your help!

Hello everyone,

I think I found the solution at last. There is an Addon called “Vaadinn ContextMenu” (https://vaadin.com/directory#!addon/vaadin-contextmenu)

It allows to use addGridHeaderContextMenuListener, It may will be good for me.