use of com.vaadin.shared.MouseEventDetails in project opennms by OpenNMS.
the class VTopologyComponent method vertexClickHandler.
private Handler<GWTVertex> vertexClickHandler() {
return new D3Events.Handler<GWTVertex>() {
@Override
public void call(GWTVertex vertex, int index) {
if (D3.eventDefaultPrevented()) {
return;
}
NativeEvent event = D3.getEvent();
SVGGElement vertexElement = event.getCurrentEventTarget().cast();
vertexElement.getParentElement().appendChild(vertexElement);
event.preventDefault();
event.stopPropagation();
final MouseEventDetails mouseDetails = MouseEventDetailsBuilder.buildMouseEventDetails(event, getElement());
m_serverRpc.vertexClicked(vertex.getId(), mouseDetails, Navigator.getPlatform());
}
};
}
use of com.vaadin.shared.MouseEventDetails in project opennms by OpenNMS.
the class VTopologyComponent method setVertexSelection.
@Override
public void setVertexSelection(List<String> vertIds) {
final MouseEventDetails mouseDetails = MouseEventDetailsBuilder.buildMouseEventDetails(D3.getEvent(), getElement());
m_serverRpc.marqueeSelection(vertIds.toArray(new String[] {}), mouseDetails);
}
Aggregations