mirror of
https://bitbucket.org/anguist/ntpa
synced 2026-10-05 19:31:58 +00:00
Clean up compiler warnings
This commit is contained in:
@@ -601,7 +601,7 @@ namespace NPlot
|
|||||||
{
|
{
|
||||||
private readonly int abscissaColumnNumber_;
|
private readonly int abscissaColumnNumber_;
|
||||||
private readonly DataRowCollection rows_;
|
private readonly DataRowCollection rows_;
|
||||||
private string abscissaName_;
|
//private string abscissaName_;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Constructor
|
/// Constructor
|
||||||
@@ -611,7 +611,7 @@ namespace NPlot
|
|||||||
public DataGetter_MultiRows(DataRowCollection rows, string omitThisColumn)
|
public DataGetter_MultiRows(DataRowCollection rows, string omitThisColumn)
|
||||||
{
|
{
|
||||||
rows_ = rows;
|
rows_ = rows;
|
||||||
abscissaName_ = omitThisColumn;
|
//abscissaName_ = omitThisColumn;
|
||||||
|
|
||||||
abscissaColumnNumber_ = rows_[0].Table.Columns.IndexOf(omitThisColumn);
|
abscissaColumnNumber_ = rows_[0].Table.Columns.IndexOf(omitThisColumn);
|
||||||
if (abscissaColumnNumber_ < 0)
|
if (abscissaColumnNumber_ < 0)
|
||||||
|
|||||||
+1
-1
@@ -178,7 +178,7 @@ namespace NPlot
|
|||||||
public virtual void DrawInLegend(Graphics g, Rectangle startEnd)
|
public virtual void DrawInLegend(Graphics g, Rectangle startEnd)
|
||||||
{
|
{
|
||||||
int smallerHeight = (int) (startEnd.Height*0.5f);
|
int smallerHeight = (int) (startEnd.Height*0.5f);
|
||||||
int heightToRemove = (int) (startEnd.Height*0.5f);
|
//int heightToRemove = (int) (startEnd.Height*0.5f);
|
||||||
Rectangle newRectangle = new Rectangle(startEnd.Left, startEnd.Top + smallerHeight/2, startEnd.Width, smallerHeight);
|
Rectangle newRectangle = new Rectangle(startEnd.Left, startEnd.Top + smallerHeight/2, startEnd.Width, smallerHeight);
|
||||||
g.FillRectangle(rectangleBrush_.Get(newRectangle), newRectangle);
|
g.FillRectangle(rectangleBrush_.Get(newRectangle), newRectangle);
|
||||||
g.DrawRectangle(borderPen_, newRectangle);
|
g.DrawRectangle(borderPen_, newRectangle);
|
||||||
|
|||||||
@@ -218,7 +218,7 @@ namespace NPlot
|
|||||||
PointF xPos1 = xAxis.WorldToPhysical(p1.X, false);
|
PointF xPos1 = xAxis.WorldToPhysical(p1.X, false);
|
||||||
PointF yPos1 = yAxis.WorldToPhysical(p1.Y, false);
|
PointF yPos1 = yAxis.WorldToPhysical(p1.Y, false);
|
||||||
PointF xPos2 = xAxis.WorldToPhysical(p2.X, false);
|
PointF xPos2 = xAxis.WorldToPhysical(p2.X, false);
|
||||||
PointF yPos2 = yAxis.WorldToPhysical(p2.Y, false);
|
//PointF yPos2 = yAxis.WorldToPhysical(p2.Y, false);
|
||||||
|
|
||||||
if (isStacked_)
|
if (isStacked_)
|
||||||
{
|
{
|
||||||
|
|||||||
+8
-8
@@ -212,8 +212,8 @@ namespace NPlot
|
|||||||
ArrayList smallTickPositions;
|
ArrayList smallTickPositions;
|
||||||
WorldTickPositions(physicalMin, physicalMax, out largeTickPositions, out smallTickPositions);
|
WorldTickPositions(physicalMin, physicalMax, out largeTickPositions, out smallTickPositions);
|
||||||
|
|
||||||
Point offset = new Point(0, 0);
|
//Point offset = new Point(0, 0);
|
||||||
object bb = null;
|
//object bb = null;
|
||||||
// Missed this protection
|
// Missed this protection
|
||||||
if (largeTickPositions.Count > 0)
|
if (largeTickPositions.Count > 0)
|
||||||
{
|
{
|
||||||
@@ -231,12 +231,12 @@ namespace NPlot
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
// just get the axis bounding box)
|
// just get the axis bounding box)
|
||||||
PointF dir = Utils.UnitVector(physicalMin, physicalMax);
|
//PointF dir = Utils.UnitVector(physicalMin, physicalMax);
|
||||||
Rectangle rr = new Rectangle(physicalMin.X,
|
//Rectangle rr = new Rectangle(physicalMin.X,
|
||||||
(int) ((physicalMax.X - physicalMin.X)*dir.X),
|
// (int) ((physicalMax.X - physicalMin.X)*dir.X),
|
||||||
physicalMin.Y,
|
// physicalMin.Y,
|
||||||
(int) ((physicalMax.Y - physicalMin.Y)*dir.Y));
|
// (int) ((physicalMax.Y - physicalMin.Y)*dir.Y));
|
||||||
bb = rr;
|
//bb = rr;
|
||||||
}
|
}
|
||||||
|
|
||||||
// missed protection for zero ticks
|
// missed protection for zero ticks
|
||||||
|
|||||||
+1
-1
@@ -39,7 +39,7 @@ namespace NPlot
|
|||||||
public class TextItem : IDrawable
|
public class TextItem : IDrawable
|
||||||
{
|
{
|
||||||
private Font font_;
|
private Font font_;
|
||||||
private Pen pen_ = new Pen(Color.Black);
|
//private Pen pen_ = new Pen(Color.Black);
|
||||||
private PointD start_;
|
private PointD start_;
|
||||||
private Brush textBrush_ = new SolidBrush(Color.Black);
|
private Brush textBrush_ = new SolidBrush(Color.Black);
|
||||||
private string text_ = "";
|
private string text_ = "";
|
||||||
|
|||||||
@@ -70,7 +70,7 @@ namespace NPlot.Windows
|
|||||||
private KeyEventArgs lastKeyEventArgs_;
|
private KeyEventArgs lastKeyEventArgs_;
|
||||||
private PlotContextMenu rightMenu_;
|
private PlotContextMenu rightMenu_;
|
||||||
|
|
||||||
private ArrayList selectedObjects_;
|
//private ArrayList selectedObjects_;
|
||||||
|
|
||||||
private Axis xAxis1ZoomCache_;
|
private Axis xAxis1ZoomCache_;
|
||||||
private Axis xAxis2ZoomCache_;
|
private Axis xAxis2ZoomCache_;
|
||||||
@@ -378,7 +378,7 @@ namespace NPlot.Windows
|
|||||||
Browsable(true),
|
Browsable(true),
|
||||||
Bindable(true)
|
Bindable(true)
|
||||||
]
|
]
|
||||||
public int Padding
|
public new int Padding
|
||||||
{
|
{
|
||||||
get { return ps_.Padding; }
|
get { return ps_.Padding; }
|
||||||
set { ps_.Padding = value; }
|
set { ps_.Padding = value; }
|
||||||
@@ -690,7 +690,7 @@ namespace NPlot.Windows
|
|||||||
if (e.Button == MouseButtons.Right)
|
if (e.Button == MouseButtons.Right)
|
||||||
{
|
{
|
||||||
Point here = new Point(e.X, e.Y);
|
Point here = new Point(e.X, e.Y);
|
||||||
selectedObjects_ = ps_.HitTest(here);
|
//selectedObjects_ = ps_.HitTest(here);
|
||||||
if (rightMenu_ != null)
|
if (rightMenu_ != null)
|
||||||
rightMenu_.Menu.Show(ctr, here);
|
rightMenu_.Menu.Show(ctr, here);
|
||||||
}
|
}
|
||||||
@@ -2407,8 +2407,8 @@ namespace NPlot.Windows
|
|||||||
doing_ = true;
|
doing_ = true;
|
||||||
axis_ = (Axis) o;
|
axis_ = (Axis) o;
|
||||||
|
|
||||||
PhysicalAxis[] physicalAxisList = new[]
|
//PhysicalAxis[] physicalAxisList = new[]
|
||||||
{ps.PhysicalXAxis1Cache, ps.PhysicalXAxis2Cache, ps.PhysicalYAxis1Cache, ps.PhysicalYAxis2Cache};
|
// {ps.PhysicalXAxis1Cache, ps.PhysicalXAxis2Cache, ps.PhysicalYAxis1Cache, ps.PhysicalYAxis2Cache};
|
||||||
|
|
||||||
if (ps.PhysicalXAxis1Cache.Axis == axis_)
|
if (ps.PhysicalXAxis1Cache.Axis == axis_)
|
||||||
physicalAxis_ = ps.PhysicalXAxis1Cache;
|
physicalAxis_ = ps.PhysicalXAxis1Cache;
|
||||||
@@ -2520,7 +2520,7 @@ namespace NPlot.Windows
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public class MouseWheelZoom : Interaction
|
public class MouseWheelZoom : Interaction
|
||||||
{
|
{
|
||||||
private Point point_ = new Point(-1, -1);
|
//private Point point_ = new Point(-1, -1);
|
||||||
private float sensitivity_ = 60.0f;
|
private float sensitivity_ = 60.0f;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|||||||
@@ -136,7 +136,7 @@ namespace Ntp.Analyzer.Data.File
|
|||||||
try {
|
try {
|
||||||
IPHostEntry hostEntry = Dns.GetHostEntry (ip);
|
IPHostEntry hostEntry = Dns.GetHostEntry (ip);
|
||||||
name = hostEntry.HostName;
|
name = hostEntry.HostName;
|
||||||
} catch (Exception e) {
|
} catch {
|
||||||
name = ip.ToString ();
|
name = ip.ToString ();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user