Fix:修复给概要节点设置样式概要节点会消失的问题
This commit is contained in:
parent
1b1551c6e3
commit
839c79405f
@ -36,15 +36,14 @@ function createGeneralizationNode () {
|
|||||||
|
|
||||||
// 更新概要节点
|
// 更新概要节点
|
||||||
function updateGeneralization () {
|
function updateGeneralization () {
|
||||||
|
if (this.isGeneralization) return
|
||||||
this.removeGeneralization()
|
this.removeGeneralization()
|
||||||
this.createGeneralizationNode()
|
this.createGeneralizationNode()
|
||||||
}
|
}
|
||||||
|
|
||||||
// 渲染概要节点
|
// 渲染概要节点
|
||||||
function renderGeneralization () {
|
function renderGeneralization () {
|
||||||
if (this.isGeneralization) {
|
if (this.isGeneralization) return
|
||||||
return
|
|
||||||
}
|
|
||||||
if (!this.checkHasGeneralization()) {
|
if (!this.checkHasGeneralization()) {
|
||||||
this.removeGeneralization()
|
this.removeGeneralization()
|
||||||
this._generalizationNodeWidth = 0
|
this._generalizationNodeWidth = 0
|
||||||
@ -67,6 +66,7 @@ function renderGeneralization () {
|
|||||||
|
|
||||||
// 删除概要节点
|
// 删除概要节点
|
||||||
function removeGeneralization () {
|
function removeGeneralization () {
|
||||||
|
if (this.isGeneralization) return
|
||||||
if (this._generalizationLine) {
|
if (this._generalizationLine) {
|
||||||
this._generalizationLine.remove()
|
this._generalizationLine.remove()
|
||||||
this._generalizationLine = null
|
this._generalizationLine = null
|
||||||
@ -87,6 +87,7 @@ function removeGeneralization () {
|
|||||||
|
|
||||||
// 隐藏概要节点
|
// 隐藏概要节点
|
||||||
function hideGeneralization () {
|
function hideGeneralization () {
|
||||||
|
if (this.isGeneralization) return
|
||||||
if (this._generalizationLine) {
|
if (this._generalizationLine) {
|
||||||
this._generalizationLine.hide()
|
this._generalizationLine.hide()
|
||||||
}
|
}
|
||||||
@ -97,6 +98,7 @@ function hideGeneralization () {
|
|||||||
|
|
||||||
// 显示概要节点
|
// 显示概要节点
|
||||||
function showGeneralization () {
|
function showGeneralization () {
|
||||||
|
if (this.isGeneralization) return
|
||||||
if (this._generalizationLine) {
|
if (this._generalizationLine) {
|
||||||
this._generalizationLine.show()
|
this._generalizationLine.show()
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user