use of org.eclipse.draw2d.ConnectionLocator in project archi by archimatetool.
the class AbstractDiagramConnectionFigure method setLabelLocator.
private void setLabelLocator(int position) {
Locator locator = null;
switch(position) {
case IDiagramModelConnection.CONNECTION_TEXT_POSITION_SOURCE:
locator = new ArchiConnectionEndpointLocator(this, false);
break;
case IDiagramModelConnection.CONNECTION_TEXT_POSITION_MIDDLE:
locator = new ConnectionLocator(this, ConnectionLocator.MIDDLE);
break;
case IDiagramModelConnection.CONNECTION_TEXT_POSITION_TARGET:
locator = new ArchiConnectionEndpointLocator(this, true);
break;
}
setConstraint(getConnectionLabel(), locator);
}
Aggregations