Vaadin 7 Table row selection issue

I’m using Vaadin 7 beta 9. I’m facing a strange issue in Table.

When I use custom class in Table Column, clicking on any cell of that column does not select the row.
Example, if this is my column definition

dataContainer.addContainerProperty(DeviceProperty.BATTERY, BatteryWidget.class, null);

then clicking on any element of BATTERY column does not select the table row.

but when i change the column type to string

dataContainer.addContainerProperty(DeviceProperty.BATTERY, String.class, null);

it starts working as expected.

First I thought that this is the issue with my widget, but I tried the same with Label and the issue was reproducible.
I’ve attached a screensort where I’ve changed te column type to Label. If I click on the cell of this column, then the Label’s text gets selected but the Table’s row is not highlighted.

Is this a bug in Vaadin 7 or am I wrong somewhere. (This is my fist Vaadin Project, kind of newbie in this framework)

Thanks.
12640.png

No solution on this? really… Such slow forum!

You are using Vaadin 7.

Vaadin 7 has not yet been released.

Most users on the forum are not using Vaadin 7, and so cannot offer any help.

For custom components, this is
enhancement request #6967
.

However, it should work for Label, Embedded and (read-only) TextField “out of the box”. If it doesn’t, there is a regression somewhere - you could
create a ticket
about it. Based on a quick look, at least the code for this is still in VScrollTableRow.getEventTargetTdOrTr(Event).

As for the forum being slow: sometimes you get a quick answer (somebody who knows how to answer spots the question and has a moment to answer), sometimes not, but it is free… You can also get
commercial support
if you need a guarantee to get an answer.

Thanks for the response. I’m sorry if I sounded offensive by saying “slow forum”. I’m new in Vaadin and I wanted someone to atleast confirm that this is a bug and not an error in my code. Vaadin is a really amazing framework and you guys are doing a great job.

One more help is needed. Can someone raise a ticket about this issue? I do not have permission to do so.

You can create it if you first register at dev.vaadin.com (top right on the page).

Hello Henri,
Is there any chance to get the feature (#6967) in the near future? The ticket seems not yet processed.

l.

The difficulty with that would be to design what exactly should be passed through where. In my opinion, implementing an interface that is designed only for the use of VScrollTable is not a good solution, as the components could be embedded elsewhere in similar contexts. If the interface is more generic, how to define it so that it makes sense in a reasonable set of possible contexts - remembering that it becomes a part of public API and hard to change in the future.

I would not hold my breath on this, although a good proposal on how exactly to do this might help take things forward. Even just extracting the test to a separate method (probably on the level of the Table to make it possible to override in practice) would make it possible to get around the limitation in some way.

Teppo Kurki did add-on solution which resolved my problem.
https://vaadin.com/forum#!/thread/4210494