Do not allow for components like traces, jumpers and wires to be reduced

to nothing by dragging connected components
This commit is contained in:
bancika
2020-12-11 21:00:11 +01:00
parent b3ce9db691
commit f386d79a26
2 changed files with 8 additions and 1 deletions
@@ -1373,6 +1373,9 @@ public class Presenter implements IPlugInPort {
// At least one control point went out of bounds. // At least one control point went out of bounds.
return null; return null;
} }
} else {
// for non-affected points just add extra space so we are comparing apples with apples later
controlPoints[index].setLocation(controlPoints[index].getX() + extraSpace, controlPoints[index].getY() + extraSpace);
} }
// For control points that may overlap, just write null, // For control points that may overlap, just write null,
// we'll ignore them later. // we'll ignore them later.
@@ -3297,7 +3297,11 @@
<org.diylc.appframework.update.Change> <org.diylc.appframework.update.Change>
<changeType>IMPROVEMENT</changeType> <changeType>IMPROVEMENT</changeType>
<description>Apply context menu rotation and mirroring to SMD components</description> <description>Apply context menu rotation and mirroring to SMD components</description>
</org.diylc.appframework.update.Change> </org.diylc.appframework.update.Change>
<org.diylc.appframework.update.Change>
<changeType>IMPROVEMENT</changeType>
<description>Do not allow for components like traces, jumpers and wires to be reduced to nothing by dragging connected components</description>
</org.diylc.appframework.update.Change>
</changes> </changes>
<url>https://github.com/bancika/diy-layout-creator/releases</url> <url>https://github.com/bancika/diy-layout-creator/releases</url>
</org.diylc.appframework.update.Version> </org.diylc.appframework.update.Version>