diff --git a/src/component/tooltip.js b/src/component/tooltip.js index ef54a4d99202a9bcccd250f8b46dbefec0af8230..262bad3396011db106046b6713b97ddf7f4070b3 100644 --- a/src/component/tooltip.js +++ b/src/component/tooltip.js @@ -1300,8 +1300,8 @@ define(function (require) { }, _setSelectedMap : function () { - if (this.option.legend && this.option.legend.selected) { - this._selectedMap = this.option.legend.selected; + if (this.component.legend) { + this._selectedMap = zrUtil.clone(this.component.legend.getSelectedMap()); } else { this._selectedMap = {}; diff --git a/src/echarts.js b/src/echarts.js index 51b6be95a91e5501f4bef691584a8a7501576f0c..2479602c125b9d482a45f42af5fe7082d1491865 100644 --- a/src/echarts.js +++ b/src/echarts.js @@ -603,7 +603,7 @@ define(function (require) { } var componentList = [ - 'title', 'tooltip', 'legend', 'dataRange', + 'title', 'legend', 'tooltip', 'dataRange', 'grid', 'dataZoom', 'xAxis', 'yAxis', 'polar' ];