Replies: 1 comment
-
我测了一下,用原生Cesium API改也这样,这可能是不支持这样改 或者是 Cesium的bug。
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
version
<script setup> import { ref, getCurrentInstance, onMounted } from 'vue' // state const wall1 = ref(null) let aaa = ref('red') // methods const onEntityEvt = e => { console.log(e) if (e.type == "onmouseover") { aaa.value = 'blue' } else if (e.type == "onmouseout") { aaa.value = 'red' } } const onViewerReady = cesiumInstance => { console.log('viewer ready') } // life cycle onMounted(() => { wall1.value.creatingPromise.then(instances => { console.log(instances); instances.viewer.zoomTo(instances.viewer.entities) }) }) </script> <style> </style>cesium":1.98.1
vue: 3.0.0
"vue-cesium": "^3.1.0",
代码如下
<vc-viewer @ready="onViewerReady">
<vc-entity @click="onEntityEvt" @mouseOver="onEntityEvt" @mouseout="onEntityEvt">
Beta Was this translation helpful? Give feedback.
All reactions