|
@@ -6,7 +6,7 @@
|
|
|
<script lang="ts" setup>
|
|
|
import GeoTeleport from "@/views/graphic/geos/geo-teleport.vue";
|
|
|
import { drawRef, FocusVector, VectorType } from "@/hook/useGraphic";
|
|
|
-import { computed, ref, toRaw, UnwrapRef } from "vue";
|
|
|
+import { computed, ref, toRaw, UnwrapRef, watchEffect } from "vue";
|
|
|
import { dataService } from "@/graphic/Service/DataService";
|
|
|
import GeoActions from "@/graphic/enum/GeoActions";
|
|
|
import { UITypeExtend } from "@/views/graphic/menus";
|
|
@@ -110,7 +110,7 @@ const appendMenus =
|
|
|
{
|
|
|
key: VectorEvents.AddCrossPoint,
|
|
|
icon: "control_a",
|
|
|
- text: "加控制点",
|
|
|
+ text: "控制点",
|
|
|
onClick: clickHandlerFactory(VectorEvents.AddCrossPoint),
|
|
|
},
|
|
|
// {
|
|
@@ -151,6 +151,17 @@ const menus = ref([
|
|
|
},
|
|
|
]);
|
|
|
|
|
|
+watchEffect(() => {
|
|
|
+ const data = menus.value.find((item) => item.key === VectorEvents.AddCrossPoint);
|
|
|
+ if (!data) return;
|
|
|
+ data.hide = [
|
|
|
+ VectorStyle.DoubleDashedLine,
|
|
|
+ VectorStyle.DoubleSolidLine,
|
|
|
+ VectorStyle.Greenbelt,
|
|
|
+ VectorStyle.BrokenLine,
|
|
|
+ ].includes(style.value);
|
|
|
+});
|
|
|
+
|
|
|
const active = computed(() =>
|
|
|
toRaw(childMenus.value) === lineTypeMenu
|
|
|
? menus.value[0]
|