diff --git a/src/drawApp/graphics/SectionInteraction.ts b/src/drawApp/graphics/SectionInteraction.ts index 0d33094..1184fba 100644 --- a/src/drawApp/graphics/SectionInteraction.ts +++ b/src/drawApp/graphics/SectionInteraction.ts @@ -1,6 +1,10 @@ import * as pb_1 from 'google-protobuf'; import { GraphicDataBase } from './GraphicDataBase'; -import { ISectionData, Section } from 'src/graphics/section/Section'; +import { + ISectionData, + Section, + SectionType, +} from 'src/graphics/section/Section'; import { graphicData } from 'src/protos/stationLayoutGraphics'; import { DisplayObject, FederatedMouseEvent, IPointData } from 'pixi.js'; import { @@ -167,7 +171,7 @@ export class SectionOperateInteraction extends GraphicInteractionPlugin
onContextMenu(e: FederatedMouseEvent) { const target = e.target as DisplayObject; const section = target.getGraphic
(); - if (!section) return; + if (!section || section.datas.sectionType != SectionType.Physical) return; this.app.updateSelected(section); const simulationId = useLineStore().simulationId || ''; const mapId = useLineStore().mapId as number;