From 0fa88f9c2e3c8ce335e7cd6dfc6c8e5641950735 Mon Sep 17 00:00:00 2001
From: liuyg <376836862@qq.com>
Date: Wed, 09 Feb 2022 15:53:24 +0800
Subject: [PATCH] +弹窗图片可点击,列表展示文字区域点击是定位,图片可点击,+活动打开后隐藏右侧控制栏,+操作方式更改
---
src/store/modules/mobile.js | 60 ++++++++++++++++++++++++++++++++++++------------------------
1 files changed, 36 insertions(+), 24 deletions(-)
diff --git a/src/store/modules/mobile.js b/src/store/modules/mobile.js
index 2df62a2..6a2d88c 100644
--- a/src/store/modules/mobile.js
+++ b/src/store/modules/mobile.js
@@ -75,6 +75,7 @@
drawALineLayerMany: null, //活动路线图层
drawAPointLayerMany: null, //活动点图层
isOpenDrawALineMany: null, //是否开启活动
+ seeRight: true, //右侧控制栏显影
},
mutations: {
MSET_VIEWER(state, viewer) {
@@ -224,9 +225,9 @@
state.startPointFn(); //移动默认视角
state.areaLayer.show = true; //绿布
//2.5D视角限制
- state.mviewer.scene.screenSpaceCameraController.minimumZoomDistance = 190;
+ state.mviewer.scene.screenSpaceCameraController.minimumZoomDistance = 80;
// 最大
- state.mviewer.scene.screenSpaceCameraController.maximumZoomDistance = 400;
+ state.mviewer.scene.screenSpaceCameraController.maximumZoomDistance = 200;
// 设置相机缩小时的速率
state.mviewer.scene.screenSpaceCameraController._minimumZoomRate = 2000;
// 设置相机放大时的速率
@@ -335,6 +336,9 @@
state.select.overlay = data[0];
state.select.color = data[1];
},
+ SET_SeeAndNotSee(state, data) {
+ state.seeRight = data;
+ },
},
actions: {
MSET_CREADE({ state, commit, dispatch }) {
@@ -437,6 +441,7 @@
// console.log(state.dimension);
if (state.dimension != "2.5D") {
// if (true) {
+ // if (true) {
dispatch("mapFlyTo", {
//飞入
lntLat: [Position.lng, Position.lat, Position.alt],
@@ -445,28 +450,35 @@
roll: Position.roll,
});
} else {
- state.mviewer.camera.setView({
- // Cesium的坐标是以地心为原点,一向指向南美洲,一向指向亚洲,一向指向北极州
- // fromDegrees()方法,将经纬度和高程转换为世界坐标
- destination: new global.DC.Namespace.Cesium.Cartesian3.fromDegrees(
- // 114.0351,
- // 27.6314,
- // 200.0
- Position.lng - 0.012,
- Position.lat,
- Position.alt || 15000.0
- ),
- orientation: {
- heading: global.DC.Namespace.Cesium.Math.toRadians(
- Position.heading
- ),
- pitch: global.DC.Namespace.Cesium.Math.toRadians(Position.pitch),
- // heading: data.heading,
- // pitch: data.pitch,
- roll: Position.roll,
- },
+ dispatch("mapFlyTo", {
+ //飞入
+ lntLat: [Position.lng, +Position.lat - 0.0003, 160],
+ heading: Position.heading,
+ pitch: Position.pitch,
+ roll: Position.roll,
});
- commit("MSET_MOBILEWINDOWSHIDE", false); // 显示弹窗
+ // state.mviewer.camera.setView({
+ // // Cesium的坐标是以地心为原点,一向指向南美洲,一向指向亚洲,一向指向北极州
+ // // fromDegrees()方法,将经纬度和高程转换为世界坐标
+ // destination: new global.DC.Namespace.Cesium.Cartesian3.fromDegrees(
+ // // 114.0351,
+ // // 27.6314,
+ // // 200.0
+ // Position.lng - 0.012,
+ // Position.lat - 0.0003,
+ // Position.alt || 15000.0
+ // ),
+ // orientation: {
+ // heading: global.DC.Namespace.Cesium.Math.toRadians(
+ // Position.heading
+ // ),
+ // pitch: global.DC.Namespace.Cesium.Math.toRadians(Position.pitch),
+ // // heading: data.heading,
+ // // pitch: data.pitch,
+ // roll: Position.roll,
+ // },
+ // });
+ // commit("MSET_MOBILEWINDOWSHIDE", false); // 显示弹窗
}
// })
commit("MSET_POPUPDOM", popupsDom);
@@ -540,7 +552,7 @@
// 自定义回调
setTimeout(() => {
data.fn();
- }, 500);
+ }, 200);
}
if (!data.noOpen) {
setTimeout(() => {
--
Gitblit v1.9.3