prmr / JetUML

A desktop application for fast UML diagramming.
GNU General Public License v3.0
625 stars 125 forks source link

Issue#437 Fix get co-removals for sequence diagrams #452

Closed maddy0218 closed 2 years ago

maddy0218 commented 2 years ago

Changes were made to fix issue #437, ensuring that when the user deletes a ConstructorEdge, downstream ImplicitParameterNode objects are not deleted, as well.

To fix this, a conditional statement was added to SequenceDiagramBuilder.getCoRemovals() which checks if the input diagram element is a ConstructorEdge. If so, downstream ImplicitParameterNode objects are removed from the list to be returned. A new test was written to consider the behavior of getCoRemovals() with a ConstructorEdge. An unrelated annotation error was also fixed in TestControlFlow.

Here is an example scenario: image

Before applying this fix: image

After fixing applying this fix: image