修复饼图在Inspector上修改相关参数后不刷新的问题

This commit is contained in:
monitor1394
2023-07-28 08:09:31 +08:00
parent f867ac7efd
commit 18c0d3218d
3 changed files with 16 additions and 2 deletions

View File

@@ -76,13 +76,13 @@ namespace XCharts.Runtime
public override void UpdateSerieContext()
{
var needCheck = m_LegendEnter || m_LegendExiting || (chart.isPointerInChart && PointerIsInPieSerie(serie, chart.pointerPos));
var needCheck = m_LegendEnter || m_LegendExiting || m_ForceUpdateSerieContext || (chart.isPointerInChart && PointerIsInPieSerie(serie, chart.pointerPos));
var needInteract = false;
var interactEnable = serie.animation.enable && serie.animation.interaction.enable;
Color32 color, toColor;
if (!needCheck)
{
if (m_LastCheckContextFlag != needCheck)
if (m_LastCheckContextFlag != needCheck || m_ForceUpdateSerieContext)
{
serie.context.pointerItemDataIndex = -1;
serie.context.pointerEnter = false;