public void previewDragStart() throws VetoDragException {
// create new connector for dragged ShapeConnectorStart
if (context.draggable instanceof ShapeConnectorStart) {
diagram.clearSelection();
ShapeConnectorStart ep = (ShapeConnectorStart) context.draggable;
ep.setWidget(ep.createEndPointImage());
ep.setLeft(getDraggableCenterLeft(ep));
ep.setTop(getDraggableCenterTop(ep));
if (ep.connector == null) {
ep.shape.endPoints.remove(ep);
ep.shape.hideShapeConnectorStartPionts();
ep.removeHandlers();
ep.removeStyle();
DOM.setStyleAttribute(ep.getElement(), "cursor", "crosshair");
if (ep.connector == null) {
int startLeft = ep.getOverlapingCP().getCenterLeft();
int startTop = ep.getOverlapingCP().getCenterTop();
int endLeft = ep.getLeft();
int endTop = ep.getTop();
ep.connector = diagram.createConnector(startLeft, startTop, endLeft, endTop, ep, ep.shape.connectorsStyle);
}
ep.connector.startEndPoint.glueToConnectionPoint(ep.getOverlapingCP());
}
}
super.previewDragStart();
}