| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748 |
- namespace Easychart.Finance.Win
- {
- using Easychart.Finance;
- using System;
- public class ChartDragInfo : IDisposable
- {
- public int[] AreaHeight;
- public double AreaMaxY;
- public double AreaMinY;
- public DateTime EndTime;
- public FormulaHitInfo HitInfo;
- public DateTime StartTime;
- public ChartDragInfo(FormulaChart Chart, FormulaHitInfo HitInfo)
- {
- this.HitInfo = HitInfo;
- this.AreaHeight = new int[Chart.Areas.Count];
- FormulaAxisY axisY = HitInfo.AxisY;
- if ((axisY == null) && (HitInfo.Area != null))
- {
- axisY = HitInfo.Area.AxisY;
- }
- if (axisY != null)
- {
- this.AreaMinY = axisY.MinY;
- this.AreaMaxY = axisY.MaxY;
- }
- for (int i = 0; i < Chart.Areas.Count; i++)
- {
- FormulaArea area = Chart.Areas[i];
- this.AreaHeight[i] = area.Rect.Height;
- }
- this.StartTime = Chart.StartTime;
- this.EndTime = Chart.EndTime;
- }
- /// <summary>
- /// 执行与释放或重置非托管资源相关的应用程序定义的任务。
- /// </summary>
- /// <exception cref="System.NotImplementedException"></exception>
- public void Dispose()
- {
- AreaHeight = null;
- }
- }
- }
|