Community
Participate
Working Groups
I have no problem calling deactivationFigure() in AbstractConnectionEditPart if my figure (PolylineConnection) doesn't have a decoration. As soon as I add a "decoration" to my figure, PolygonDecoration sourceDecoration = new PolygonDecoration(); ((PolylineConnection) connectionFigure).setSourceDecoration(sourceDecoration); deactivationFigure() gets ArrayIndexOutOfBoundsException. Here is the stack trace. java.lang.ArrayIndexOutOfBoundsException: -1 at java.util.ArrayList.remove(Unknown Source) at org.eclipse.draw2d.graph.ShortestPathRouter.internalRemoveObstacle(ShortestPathRouter.java:379) at org.eclipse.draw2d.graph.ShortestPathRouter.removeObstacle(ShortestPathRouter.java:594) at org.eclipse.draw2d.ShortestPathConnectionRouter.removeChild(ShortestPathConnectionRouter.java:238) at org.eclipse.draw2d.ShortestPathConnectionRouter.unhookAll(ShortestPathConnectionRouter.java:114) at org.eclipse.draw2d.ShortestPathConnectionRouter.remove(ShortestPathConnectionRouter.java:226) at org.eclipse.draw2d.PolylineConnection.setConnectionRouter(PolylineConnection.java:229) at org.eclipse.draw2d.ConnectionLayer.remove(ConnectionLayer.java:75) at org.eclipse.gef.editparts.AbstractConnectionEditPart.deactivateFigure(AbstractConnectionEditPart.java:122)
Looking at the stack trace this seems to be something related to ShortestPathConnection router. However, I fear that from the provided information alone, this will not be reproducible. Could you provide a code snippet that could help to reproduce the problem?