Fix:删除无用代码,修复鼠标悬浮节点上报错不显示展开收起按钮的问题
This commit is contained in:
parent
9bde9ffaf3
commit
4e7d59b328
@ -10,9 +10,7 @@ function createExpandNodeContent() {
|
|||||||
// 根据配置判断是否显示数量按钮
|
// 根据配置判断是否显示数量按钮
|
||||||
if (this.mindMap.opt.isShowExpandNum) {
|
if (this.mindMap.opt.isShowExpandNum) {
|
||||||
// 展开的节点
|
// 展开的节点
|
||||||
this._openExpandNode = SVG()
|
this._openExpandNode = SVG().text()
|
||||||
.text()
|
|
||||||
.size(this.expandBtnSize, this.expandBtnSize)
|
|
||||||
// 文本垂直居中
|
// 文本垂直居中
|
||||||
this._openExpandNode.attr({
|
this._openExpandNode.attr({
|
||||||
'text-anchor': 'middle',
|
'text-anchor': 'middle',
|
||||||
@ -126,11 +124,7 @@ function renderExpandBtn() {
|
|||||||
this._expandBtn.on('click', e => {
|
this._expandBtn.on('click', e => {
|
||||||
e.stopPropagation()
|
e.stopPropagation()
|
||||||
// 展开收缩
|
// 展开收缩
|
||||||
this.mindMap.execCommand(
|
this.mindMap.execCommand('SET_NODE_EXPAND', this, !this.getData('expand'))
|
||||||
'SET_NODE_EXPAND',
|
|
||||||
this,
|
|
||||||
!this.getData('expand')
|
|
||||||
)
|
|
||||||
this.mindMap.emit('expand_btn_click', this)
|
this.mindMap.emit('expand_btn_click', this)
|
||||||
})
|
})
|
||||||
this._expandBtn.on('dblclick', e => {
|
this._expandBtn.on('dblclick', e => {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user