优化Legend初始化,防止出现预设下删除异常的问题

This commit is contained in:
monitor1394
2020-04-10 07:32:59 +08:00
parent 73e713802c
commit 80a946d0c6
3 changed files with 9 additions and 5 deletions

View File

@@ -291,7 +291,7 @@ namespace XCharts
totalLegend++;
}
m_Legend.RemoveButton();
ChartHelper.DestroyAllChildren(legendObject.transform);
ChartHelper.HideAllObject(legendObject);
if (!m_Legend.show) return;
for (int i = 0; i < datas.Count; i++)
{