|
@@ -357,14 +357,16 @@ export default class Layer {
|
|
|
case VectorEvents.MinusCrossPoint:
|
|
|
if (selectItem && selectItem.vectorId) {
|
|
|
const curvePoint = dataService.getCurveRoadPoint(selectItem.vectorId);
|
|
|
- const curveRoad = dataService.getCurveRoad(curvePoint.parent);
|
|
|
- if (curveRoad.points.length > 3) {
|
|
|
- curveRoadService.subCPoint(curveRoad, curvePoint.getIndex());
|
|
|
- curveRoadService.setLanes(curveRoad.vectorId);
|
|
|
- stateService.clearEventName();
|
|
|
+ if (curvePoint) {
|
|
|
+ const curveRoad = dataService.getCurveRoad(curvePoint.parent);
|
|
|
+ if (curveRoad.points.length > 3) {
|
|
|
+ curveRoadService.subCPoint(curveRoad, curvePoint.getIndex());
|
|
|
+ curveRoadService.setLanes(curveRoad.vectorId);
|
|
|
+ stateService.clearEventName();
|
|
|
+ }
|
|
|
+ this.history.save();
|
|
|
+ this.renderer.autoRedraw();
|
|
|
}
|
|
|
- this.history.save();
|
|
|
- this.renderer.autoRedraw();
|
|
|
}
|
|
|
break;
|
|
|
}
|
|
@@ -1001,6 +1003,7 @@ export default class Layer {
|
|
|
if (e instanceof TouchEvent) {
|
|
|
stateService.clearSelectItem();
|
|
|
stateService.clearDraggingItem();
|
|
|
+ this.uiControl.focusVector = null;
|
|
|
this.renderer.autoRedraw();
|
|
|
}
|
|
|
return;
|