Fixes code according to modern code style. Fixes a few expression bugs.
This commit is contained in:
parent
89eea25e5f
commit
970fd563b2
3324 changed files with 441118 additions and 433755 deletions
|
|
@ -3,75 +3,77 @@ using System.Drawing;
|
|||
|
||||
namespace Server.Engines.Reports
|
||||
{
|
||||
// Modified from MS sample
|
||||
// Modified from MS sample
|
||||
|
||||
//*********************************************************************
|
||||
//
|
||||
// ChartItem Class
|
||||
//
|
||||
// This class represents a data point in a chart
|
||||
//
|
||||
//*********************************************************************
|
||||
//*********************************************************************
|
||||
//
|
||||
// ChartItem Class
|
||||
//
|
||||
// This class represents a data point in a chart
|
||||
//
|
||||
//*********************************************************************
|
||||
|
||||
public class DataItem
|
||||
{
|
||||
private DataItem() {}
|
||||
|
||||
public DataItem(string label, string desc, float data, float start, float sweep, Color clr)
|
||||
{
|
||||
Label = label;
|
||||
Description = desc;
|
||||
Value = data;
|
||||
StartPos = start;
|
||||
SweepSize = sweep;
|
||||
ItemColor = clr;
|
||||
}
|
||||
public class DataItem
|
||||
{
|
||||
private DataItem()
|
||||
{
|
||||
}
|
||||
|
||||
public string Label { get; set; }
|
||||
public DataItem(string label, string desc, float data, float start, float sweep, Color clr)
|
||||
{
|
||||
Label = label;
|
||||
Description = desc;
|
||||
Value = data;
|
||||
StartPos = start;
|
||||
SweepSize = sweep;
|
||||
ItemColor = clr;
|
||||
}
|
||||
|
||||
public string Description { get; set; }
|
||||
public string Label{ get; set; }
|
||||
|
||||
public float Value { get; set; }
|
||||
public string Description{ get; set; }
|
||||
|
||||
public Color ItemColor { get; set; }
|
||||
public float Value{ get; set; }
|
||||
|
||||
public float StartPos { get; set; }
|
||||
public Color ItemColor{ get; set; }
|
||||
|
||||
public float SweepSize { get; set; }
|
||||
}
|
||||
public float StartPos{ get; set; }
|
||||
|
||||
//*********************************************************************
|
||||
//
|
||||
// Custom Collection for ChartItems
|
||||
//
|
||||
//*********************************************************************
|
||||
public float SweepSize{ get; set; }
|
||||
}
|
||||
|
||||
public class ChartItemsCollection : CollectionBase
|
||||
{
|
||||
public DataItem this[int index]
|
||||
{
|
||||
get => (DataItem)(List[index]);
|
||||
set => List[index] = value;
|
||||
}
|
||||
|
||||
public int Add(DataItem value)
|
||||
{
|
||||
return List.Add(value);
|
||||
}
|
||||
|
||||
public int IndexOf(DataItem value)
|
||||
{
|
||||
return List.IndexOf(value);
|
||||
}
|
||||
|
||||
public bool Contains(DataItem value)
|
||||
{
|
||||
return List.Contains(value);
|
||||
}
|
||||
//*********************************************************************
|
||||
//
|
||||
// Custom Collection for ChartItems
|
||||
//
|
||||
//*********************************************************************
|
||||
|
||||
public void Remove(DataItem value)
|
||||
{
|
||||
List.Remove(value);
|
||||
}
|
||||
}
|
||||
public class ChartItemsCollection : CollectionBase
|
||||
{
|
||||
public DataItem this[int index]
|
||||
{
|
||||
get => (DataItem)List[index];
|
||||
set => List[index] = value;
|
||||
}
|
||||
|
||||
public int Add(DataItem value)
|
||||
{
|
||||
return List.Add(value);
|
||||
}
|
||||
|
||||
public int IndexOf(DataItem value)
|
||||
{
|
||||
return List.IndexOf(value);
|
||||
}
|
||||
|
||||
public bool Contains(DataItem value)
|
||||
{
|
||||
return List.Contains(value);
|
||||
}
|
||||
|
||||
public void Remove(DataItem value)
|
||||
{
|
||||
List.Remove(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue