提交 96c5fb6d 编写于 作者: L lang

Fix #2988

上级 3d4c593c
......@@ -255,12 +255,14 @@ define(function (require) {
zr.off('click', tryShow);
zr.off('mousemove', tryShow);
zr.off('mouseout', this._hide);
zr.off('globalout', this._hide);
if (tooltipModel.get('triggerOn') === 'click') {
zr.on('click', tryShow, this);
}
else {
zr.on('mousemove', tryShow, this);
zr.on('mouseout', this._hide, this);
zr.on('globalout', this._hide, this);
}
},
......@@ -1100,6 +1102,8 @@ define(function (require) {
type: 'hideTip',
from: this.uid
});
this._lastX = this._lastY = null;
},
dispose: function (ecModel, api) {
......@@ -1112,6 +1116,7 @@ define(function (require) {
zr.off('click', this._tryShow);
zr.off('mousemove', this._tryShow);
zr.off('mouseout', this._hide);
zr.off('globalout', this._hide);
api.off('showTip', this._manuallyShowTip);
api.off('hideTip', this._manuallyHideTip);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册