fix: 缩放文本和表格元素时,重复接收emitter

This commit is contained in:
pipipi-pikachu 2021-05-26 21:13:41 +08:00
parent b5e8c23756
commit 610c818e5a
2 changed files with 4 additions and 0 deletions

View File

@ -103,6 +103,8 @@ export default defineComponent({
const realHeightCache = ref(-1) const realHeightCache = ref(-1)
const scaleElementStateListener = (state: boolean) => { const scaleElementStateListener = (state: boolean) => {
if (handleElementId.value !== props.elementInfo.id) return
isScaling.value = state isScaling.value = state
if (state) editable.value = false if (state) editable.value = false

View File

@ -108,6 +108,8 @@ export default defineComponent({
// vuex // vuex
// //
const scaleElementStateListener = (state: boolean) => { const scaleElementStateListener = (state: boolean) => {
if (handleElementId.value !== props.elementInfo.id) return
isScaling.value = state isScaling.value = state
if (!state && realHeightCache.value !== -1) { if (!state && realHeightCache.value !== -1) {