|
@@ -526,7 +526,10 @@ export class SPolygonItem extends SGraphItem {
|
|
|
if (event.key == "Alt") {
|
|
|
this.isAlt = false;
|
|
|
} else if (event.keyCode == SKeyCode.Delete) {
|
|
|
- this.deletePoint(this.curIndex);
|
|
|
+ // 当多边形的顶点大于三个允许删除点
|
|
|
+ if (this.pointList.length > 3) {
|
|
|
+ this.deletePoint(this.curIndex);
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
this.update();
|