[LWFXEF] Handle dragging a direkt links without bendpoints without throwing exceptions
How to reproduce
- Create a new LWFXEF-based diagram with two content rectangles (e.g. two components in a component architecture
- Add a port to each of the two components and connect them wit a direct link (without any bendpoints)
- Select the link
- Try to drag the link
Description
As there are no bend points, when the controller thies access the list
where they are supposed to be stored a BasicIndexOutOfBoundsException
is thrown:
Exception in thread "JavaFX Application Thread" org.eclipse.emf.common.util.BasicEList$BasicIndexOutOfBoundsException: index=0, size=0
at org.eclipse.emf.common.util.BasicEList.get(BasicEList.java:346)
at org.fortiss.tooling.base.ui.editor.fx.visual.LayoutedLineLinkVisual.getBendPointLocation(LayoutedLineLinkVisual.java:69)
at org.eclipse.systemfocus.kernel.common.ui.javafx.lwfxef.controller.base.LinkControllerBase.getMoveDeltaFeedback(LinkControllerBase.java:206)
at org.eclipse.systemfocus.kernel.common.ui.javafx.lwfxef.controller.base.LinkControllerBase.moveBendPointVisually(LinkControllerBase.java:186)
at org.eclipse.systemfocus.kernel.common.ui.javafx.lwfxef.controller.base.LinkControllerBase$2.safeDragInProgress(LinkControllerBase.java:168)
at org.eclipse.systemfocus.kernel.common.ui.javafx.lwfxef.controller.base.DragControllerBase.dragInProgress(DragControllerBase.java:65)
...
(from redmine: issue id 3902, created on 2019-12-20, closed on 2020-03-16)
- Relations:
- relates #3873 (closed)
- Uploads: