diff --git a/src/main/java/org/openjump/advancedtools/block/DrawBlockTool.java b/src/main/java/org/openjump/advancedtools/block/DrawBlockTool.java index 65be552..26e1cf4 100644 --- a/src/main/java/org/openjump/advancedtools/block/DrawBlockTool.java +++ b/src/main/java/org/openjump/advancedtools/block/DrawBlockTool.java @@ -11,6 +11,7 @@ import com.vividsolutions.jump.I18N; import com.vividsolutions.jump.workbench.JUMPWorkbench; +import com.vividsolutions.jump.workbench.model.UndoableCommand; import org.locationtech.jts.geom.Coordinate; import org.locationtech.jts.geom.Geometry; @@ -85,9 +86,13 @@ protected void gestureFinished() throws Exception { GeometryUtils.scaleGeometry(geom2, dimension); GeometryUtils.centerGeometry(geom2, displacement); - execute(featureDrawingUtil.createAddCommand(geom2, - isRollingBackInvalidEdits(), getPanel(), this)); + // TODO: [202208 ed] lots a symbols seem to not pass geom.isValid() anymore + // disabled the check, but am not sure this is the proper solution + UndoableCommand cmd = featureDrawingUtil.createAddCommand(geom2, + /*isRollingBackInvalidEdits()*/false, getPanel(), this); + if (cmd!=null) + execute(cmd); } @Override