修复Chart在运行时动态添加Component异常的问题 (#339)

This commit is contained in:
monitor1394
2025-01-15 08:30:50 +08:00
parent ddbfd9b7ef
commit 29b1f8a8c2
3 changed files with 3 additions and 1 deletions

View File

@@ -52,6 +52,7 @@ namespace XCharts.Runtime
public MainComponent AddChartComponent(Type type)
{
InitListForFieldInfos();
if (!CanAddChartComponent(type))
{
Debug.LogError("XCharts ERROR: CanAddChartComponent:" + type.Name);