This commit is contained in:
monitor1394
2021-06-18 06:48:11 +08:00
parent f090970cc8
commit 49fd642885
16 changed files with 89 additions and 33 deletions

View File

@@ -570,7 +570,7 @@ namespace XCharts
{
if (maxCache > 0)
{
while (m_Data.Count > maxCache)
while (m_Data.Count >= maxCache)
{
m_NeedUpdateFilterData = true;
m_Data.RemoveAt(m_InsertDataToHead ? m_Data.Count - 1 : 0);

View File

@@ -1024,7 +1024,6 @@ namespace XCharts
var p2 = new Vector3(dataZoom.runtimeX, dataZoom.runtimeY + dataZoom.runtimeHeight);
var p3 = new Vector3(dataZoom.runtimeX + dataZoom.runtimeWidth, dataZoom.runtimeY + dataZoom.runtimeHeight);
var p4 = new Vector3(dataZoom.runtimeX + dataZoom.runtimeWidth, dataZoom.runtimeY);
var xAxis = chart.GetXAxis(0);
var lineColor = dataZoom.lineStyle.GetColor(chart.theme.dataZoom.dataLineColor);
var lineWidth = dataZoom.lineStyle.GetWidth(chart.theme.dataZoom.dataLineWidth);
var borderWidth = dataZoom.borderWidth == 0 ? chart.theme.dataZoom.borderWidth : dataZoom.borderWidth;

View File

@@ -1497,7 +1497,7 @@ namespace XCharts
private void CheckMaxCache()
{
if (m_MaxCache <= 0) return;
while (m_Data.Count > m_MaxCache)
while (m_Data.Count >= m_MaxCache)
{
m_NeedUpdateFilterData = true;
if (m_InsertDataToHead) RemoveData(m_Data.Count - 1);

View File

@@ -928,7 +928,6 @@ namespace XCharts
var halfWid = visualMap.itemWidth / 2;
var halfHig = visualMap.itemHeight / 2;
var splitNum = visualMap.runtimeInRange.Count;
var splitWid = visualMap.itemHeight / (splitNum - 1);
var colors = visualMap.runtimeInRange;
switch (visualMap.orient)
{