优化BarChartTooltipTriggerItem时的表现

This commit is contained in:
monitor1394
2023-08-10 13:19:05 +08:00
parent 01a49de373
commit 9ed80d3b59
4 changed files with 7 additions and 6 deletions

View File

@@ -454,10 +454,10 @@ namespace XCharts.Runtime
tooltip.context.pointer = chart.pointerPos;
if (m_PointerContainer is GridCoord)
{
GetAxisCategory(m_PointerContainer.index, ref dataIndex, ref category);
if (tooltip.trigger == Tooltip.Trigger.Axis)
{
isTriggerByAxis = true;
GetAxisCategory(m_PointerContainer.index, ref dataIndex, ref category);
if (series.Count <= 1)
{
showCategory = true;

View File

@@ -25,7 +25,7 @@ namespace XCharts.Runtime
string marker, string itemFormatter, string numericFormatter, string ignoreDataDefaultContent,
ref List<SerieParams> paramList, ref string title)
{
UpdateCoordSerieParams(ref paramList, ref title, dataIndex, showCategory, category,
UpdateCoordSerieParams(ref paramList, ref title, dataIndex, true, category,
marker, itemFormatter, numericFormatter, ignoreDataDefaultContent);
}