Grid ItemClickEvent.isDoubleClick

Hi,

I am trying to catch the double click event in a Grid component through the funcion Grid.addItemClickListener. The problem is that the double click is never cathed. See the example below:

grid.addItemClickListener(event -> {

if (event.isDoubleClick()) {
System.out.println("THIS CODE IS NEVER REACHED¡¡¡¡");
}

});

So my question is if I am missing something or it is a bug in the Grid component.
I have updated to the last version of Vaadin 7.5.0

Thanks.

you can implement “ItemClickEvent.ItemClickListener” .
The method you will implement is itemClick(ItemClickEvent event). So your code above will go inside itemClick and it will work fine.
@Override
public void itemClick(ItemClickEvent event) {
if (event.isDoubleClick()) {
System.out.println(“THIS CODE IS NEVER REACHED¡¡¡¡”);
}
}