FiX:修复前进后退时data_change事件触发时渲染树数据还未更新的问题
This commit is contained in:
parent
faa2b94bc8
commit
32ce3bce17
@ -143,7 +143,6 @@ class Command {
|
|||||||
)
|
)
|
||||||
const data = simpleDeepClone(this.history[this.activeHistoryIndex])
|
const data = simpleDeepClone(this.history[this.activeHistoryIndex])
|
||||||
this.emitDataUpdatesEvent(lastData, data)
|
this.emitDataUpdatesEvent(lastData, data)
|
||||||
this.mindMap.emit('data_change', data)
|
|
||||||
return data
|
return data
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -164,7 +163,6 @@ class Command {
|
|||||||
)
|
)
|
||||||
const data = simpleDeepClone(this.history[this.activeHistoryIndex])
|
const data = simpleDeepClone(this.history[this.activeHistoryIndex])
|
||||||
this.emitDataUpdatesEvent(lastData, data)
|
this.emitDataUpdatesEvent(lastData, data)
|
||||||
this.mindMap.emit('data_change', data)
|
|
||||||
return data
|
return data
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -665,6 +665,7 @@ class Render {
|
|||||||
this.renderTree = data
|
this.renderTree = data
|
||||||
this.mindMap.render()
|
this.mindMap.render()
|
||||||
}
|
}
|
||||||
|
this.mindMap.emit('data_change', data)
|
||||||
}
|
}
|
||||||
|
|
||||||
// 获取创建新节点的行为
|
// 获取创建新节点的行为
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user