本文整理了Java中com.vaadin.v7.ui.Table.addItemClickListener()
方法的一些代码示例,展示了Table.addItemClickListener()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Table.addItemClickListener()
方法的具体详情如下:
包路径:com.vaadin.v7.ui.Table
类名称:Table
方法名:addItemClickListener
暂无
代码示例来源:origin: com.vaadin/vaadin-compatibility-server
/**
* @deprecated As of 7.0, replaced by
* {@link #addItemClickListener(ItemClickListener)}
*/
@Override
@Deprecated
public void addListener(ItemClickListener listener) {
addItemClickListener(listener);
}
代码示例来源:origin: com.haulmont.cuba/cuba-web-widgets
private void useTableSpecificContextClickListener(final Table table) {
table.addItemClickListener(new ItemClickListener() {
@Override
public void itemClick(ItemClickEvent event) {
if (event.getButton() == MouseButton.RIGHT) {
MouseEventDetails mouseEventDetails = new MouseEventDetails();
mouseEventDetails.setAltKey(event.isAltKey());
mouseEventDetails.setButton(event.getButton());
mouseEventDetails.setClientX(event.getClientX());
mouseEventDetails.setClientY(event.getClientY());
mouseEventDetails.setCtrlKey(event.isCtrlKey());
mouseEventDetails.setMetaKey(event.isMetaKey());
mouseEventDetails.setRelativeX(event.getRelativeX());
mouseEventDetails.setRelativeY(event.getRelativeY());
mouseEventDetails.setShiftKey(event.isShiftKey());
if (event.isDoubleClick()) {
mouseEventDetails.setType(0x00002);
} else {
mouseEventDetails.setType(0x00001);
}
getContextClickListener().contextClick(
new ContextClickEvent(table, mouseEventDetails));
}
}
});
}
代码示例来源:origin: com.haulmont.cuba/cuba-web
component.addItemClickListener(event -> {
if (event.isDoubleClick() && event.getItem() != null) {
T tableImpl = WebAbstractTable.this.component;
内容来源于网络,如有侵权,请联系作者删除!