mirror of
https://github.com/XCharts-Team/XCharts.git
synced 2026-05-22 00:20:18 +00:00
修复ConvertXYAxis()多次调用后图表异常的问题
This commit is contained in:
@@ -73,6 +73,7 @@ slug: /changelog
|
||||
|
||||
## master
|
||||
|
||||
* (2024.04.23) 修复`ConvertXYAxis()`多次调用后图表异常的问题
|
||||
* (2024.04.22) 修复`DataZoom`控制多个轴时的`GridCoord`获取可能不正确的问题 (#317)
|
||||
* (2024.04.22) 增加`GridCoord3D`3D坐标系
|
||||
* (2024.04.15) 优化`DateTimeUtil`时间戳转`DateTime`接口时区的问题
|
||||
|
||||
@@ -459,6 +459,17 @@ namespace XCharts.Runtime
|
||||
base.SetComponentDirty();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 重置状态。
|
||||
/// </summary>
|
||||
public override void ResetStatus()
|
||||
{
|
||||
context.minValue = 0;
|
||||
context.maxValue = 0;
|
||||
context.destMinValue = 0;
|
||||
context.destMaxValue = 0;
|
||||
}
|
||||
|
||||
public Axis Clone()
|
||||
{
|
||||
var axis = new Axis();
|
||||
|
||||
@@ -532,6 +532,7 @@ namespace XCharts.Runtime
|
||||
xAxis.context.maxValue = 0;
|
||||
yAxis.context.minValue = 0;
|
||||
yAxis.context.maxValue = 0;
|
||||
ResetChartStatus();
|
||||
RefreshChart();
|
||||
}
|
||||
}
|
||||
@@ -771,6 +772,7 @@ namespace XCharts.Runtime
|
||||
[Since("v3.10.0")]
|
||||
public void ResetChartStatus()
|
||||
{
|
||||
foreach (var component in m_Components) component.ResetStatus();
|
||||
foreach (var handler in m_SerieHandlers) handler.ForceUpdateSerieContext();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -54,6 +54,8 @@ namespace XCharts.Runtime
|
||||
|
||||
public virtual void Reset() { }
|
||||
|
||||
public virtual void ResetStatus() { }
|
||||
|
||||
public virtual void ClearData() { }
|
||||
|
||||
public virtual void ClearDirty()
|
||||
@@ -120,7 +122,7 @@ namespace XCharts.Runtime
|
||||
|
||||
internal override void SetComponent(MainComponent component)
|
||||
{
|
||||
this.component = (T) component;
|
||||
this.component = (T)component;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user