Skip to content

Commit

Permalink
Version 5.2.5
Browse files Browse the repository at this point in the history
  • Loading branch information
RudolfHenning committed Jan 25, 2021
1 parent 3c8a46d commit d80813b
Show file tree
Hide file tree
Showing 31 changed files with 192 additions and 21 deletions.
2 changes: 1 addition & 1 deletion QuickMon5/Installer/Product.wxs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi" xmlns:netfx="http://schemas.microsoft.com/wix/NetFxExtension">
<Product Id="*" Name="QuickMon 5" Language="1033" Version="5.2.4.0058" Manufacturer="Hen IT" UpgradeCode="59162023-5478-4668-A279-41c950000000">
<Product Id="*" Name="QuickMon 5" Language="1033" Version="5.2.5.0060" Manufacturer="Hen IT" UpgradeCode="59162023-5478-4668-A279-41c950000000">
<Package Id='*' Keywords='Installer' Description="QuickMon 5 Installer" Comments='QuickMon 5 is a simple monitoring and alerting tool'
Manufacturer='Hen IT' InstallerVersion='200' Languages='1033' Compressed='yes' SummaryCodepage='1252' />

Expand Down
2 changes: 1 addition & 1 deletion QuickMon5/Installer/Productx64.wxs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi" xmlns:netfx="http://schemas.microsoft.com/wix/NetFxExtension">
<Product Id="*" Name="QuickMon 5" Language="1033" Version="5.2.4.0058" Manufacturer="Hen IT" UpgradeCode="59162023-5478-4668-A279-41c950000000">
<Product Id="*" Name="QuickMon 5" Language="1033" Version="5.2.5.0060" Manufacturer="Hen IT" UpgradeCode="59162023-5478-4668-A279-41c950000000">
<Package Id='*' Keywords='Installer' Description="QuickMon 5 Installer" Comments='QuickMon 5 is a simple monitoring and alerting tool'
Manufacturer='Hen IT' InstallerVersion='200' Languages='1033' Compressed='yes' SummaryCodepage='1252' Platform="x64" />

Expand Down
Binary file removed QuickMon5/Installer/QuickMon5.0.0.msi.zip
Binary file not shown.
Binary file removed QuickMon5/Installer/QuickMon5.0.0x64.msi.zip
Binary file not shown.
Binary file removed QuickMon5/Installer/QuickMon5.0.1.msi
Binary file not shown.
Binary file removed QuickMon5/Installer/QuickMon5.0.10.msi
Binary file not shown.
Binary file removed QuickMon5/Installer/QuickMon5.0.10x64.msi
Binary file not shown.
Binary file removed QuickMon5/Installer/QuickMon5.0.1x64.msi
Binary file not shown.
Binary file removed QuickMon5/Installer/QuickMon5.0.2.msi
Binary file not shown.
Binary file removed QuickMon5/Installer/QuickMon5.0.2x64.msi
Binary file not shown.
Binary file removed QuickMon5/Installer/QuickMon5.0.3.msi
Binary file not shown.
Binary file removed QuickMon5/Installer/QuickMon5.0.3x64.msi
Binary file not shown.
Binary file removed QuickMon5/Installer/QuickMon5.0.4.msi
Binary file not shown.
Binary file removed QuickMon5/Installer/QuickMon5.0.4x64.msi
Binary file not shown.
Binary file removed QuickMon5/Installer/QuickMon5.0.5.msi
Binary file not shown.
Binary file removed QuickMon5/Installer/QuickMon5.0.5x64.msi
Binary file not shown.
Binary file removed QuickMon5/Installer/QuickMon5.0.6.msi
Binary file not shown.
Binary file removed QuickMon5/Installer/QuickMon5.0.6x64.msi
Binary file not shown.
Binary file removed QuickMon5/Installer/QuickMon5.0.7.msi
Binary file not shown.
Binary file removed QuickMon5/Installer/QuickMon5.0.7x64.msi
Binary file not shown.
Binary file removed QuickMon5/Installer/QuickMon5.0.8.msi
Binary file not shown.
Binary file removed QuickMon5/Installer/QuickMon5.0.8x64.msi
Binary file not shown.
Binary file removed QuickMon5/Installer/QuickMon5.0.9.msi
Binary file not shown.
Binary file removed QuickMon5/Installer/QuickMon5.0.9x64.msi
Binary file not shown.
2 changes: 1 addition & 1 deletion QuickMon5/QuickMon5/app.manifest
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<assembly manifestVersion="1.0" xmlns="urn:schemas-microsoft-com:asm.v1">
<assemblyIdentity version="5.2.4.0059" name="QuickMon.app"/>
<assemblyIdentity version="5.2.5.0060" name="QuickMon.app"/>
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v2">
<security>
<requestedPrivileges xmlns="urn:schemas-microsoft-com:asm.v3">
Expand Down
6 changes: 6 additions & 0 deletions QuickMon5/QuickMon5Core/Resources/ChangeLog.txt
Original file line number Diff line number Diff line change
Expand Up @@ -167,3 +167,9 @@ Change the Performance counter collector to also use aggregated Instance values
Tweaked some templates
Add Graph color/settings customisation
Add setting to allow control over main window startup size/location

Version 5.2.5
**************
First version compiled with VS2019
Graph control selected series can be changed by up/down keys
Graph control selected series can be selected by clicking on the legend
4 changes: 2 additions & 2 deletions QuickMon5/QuickMon5Core/VersionInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
[assembly: AssemblyVersion("5.2.4.0059")]
[assembly: AssemblyFileVersion("5.2.4.0059")]
[assembly: AssemblyVersion("5.2.5.0060")]
[assembly: AssemblyFileVersion("5.2.5.0060")]
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,12 @@ public GraphSeries(string name, Color lineColor) : this(name)
public bool Enabled { get; set; } = true;
public bool Selected { get; set; } = false;

#region Legend details
public string CurrentSeriesLabelText { get; set; }
public Point CurrentSeriesLabelLocation { get; set; }
public SizeF CurrentSeriesLabelSize { get; set; }
#endregion

public GraphSeries Clone()
{
GraphSeries newSeries = new GraphSeries();
Expand Down
187 changes: 173 additions & 14 deletions QuickMon5/QuickMonCoreUI/Controls/TimeGraphControl/TimeGraphControl.cs
Original file line number Diff line number Diff line change
Expand Up @@ -245,6 +245,14 @@ protected override bool ProcessCmdKey(ref Message msg, Keys keyData)
SetNextFromClosestPointSelected();
RefreshGraph();
break;
case Keys.Up:
SetPreviousSelectedSeries();
RefreshGraph();
break;
case Keys.Down:
SetNextSelectedSeries();
RefreshGraph();
break;
default:
return base.ProcessCmdKey(ref msg, keyData);
}
Expand All @@ -261,16 +269,38 @@ private void DataClickTest(MouseEventArgs e)
{
lastClickTime = DateTime.Now;

LastClickedLocation = ConvertPointToTimeValue(e.X, e.Y);
if (LastClickedLocation != null)
{
SetClosestPointSelected();
}
else
if (ShowLegendText && e.Y > (Height - legendHeight)) //legend area
{
ClosestClickedTimeValue = null;
foreach (GraphSeries s in Series)
s.Selected = false;

foreach (var enabledSeries in (from serie in Series
where serie.Enabled
select serie))
{
if (enabledSeries.CurrentSeriesLabelLocation.X <= e.X && enabledSeries.CurrentSeriesLabelLocation.X + enabledSeries.CurrentSeriesLabelSize.Width > e.X)
{
if (enabledSeries.CurrentSeriesLabelLocation.Y <= e.Y && enabledSeries.CurrentSeriesLabelLocation.Y + enabledSeries.CurrentSeriesLabelSize.Height > e.Y)
{
SetSelectedSeriesByName(enabledSeries.Name);
}
}
}
}
else
{
LastClickedLocation = ConvertPointToTimeValue(e.X, e.Y);
if (LastClickedLocation != null)
{
SetClosestPointSelected();
}
else
{
ClosestClickedTimeValue = null;
foreach (GraphSeries s in Series)
s.Selected = false;
}
}
SetHightlightSeries();

Expand Down Expand Up @@ -349,6 +379,30 @@ public GraphSeries GetSeriesByName(string name)
}
return null;
}
public int GetSeriesIndexByName(string name)
{
for (int i = 0; i < Series.Count; i++)
{
if (Series[i].Name == name)
{
return i;
}
}
return 0;
}
public void SetSelectedSeriesByName(string name)
{
foreach (var s in Series)
{
if (s.Name == name)
{
s.Selected = true;
ClosestClickedTimeSeriesName = name;
}
else
s.Selected = false;
}
}
public void SetClosestPointSelected()
{
if (LastClickedLocation != null)
Expand All @@ -365,11 +419,6 @@ public void SetClosestPointSelected()
else
s.Selected = false;
}
//if (HighlightClickedSeries)

//ClosestClickedSeries = (from s in Series
// where s.Name == closetValue.Item1
// select s).FirstOrDefault();
}
else
{
Expand Down Expand Up @@ -397,6 +446,37 @@ public void SetPreviousFromClosestPointSelected()
}
}
}

private TimeValue GetClosestPointForSeries(GraphSeries selectedSeries, TimeValue selectedPoint)
{
TimeValue tv = null;
if (selectedPoint != null)
{
TimeValue tv1 = (from sv in selectedSeries.Values
orderby sv.Time descending
where sv.Time <= selectedPoint.Time
select sv).FirstOrDefault();
TimeValue tv2 = (from sv in selectedSeries.Values
orderby sv.Time
where sv.Time >= selectedPoint.Time
select sv).FirstOrDefault();

if (tv1 != null && tv2 != null)
{
if (selectedPoint.Time.Subtract(tv1.Time) < tv2.Time.Subtract(selectedPoint.Time))
{
tv = tv1;
}
else
tv = tv2;
}
else if (tv1 != null)
tv = tv1;
else
tv = tv2;
}
return tv;
}
public void SetNextFromClosestPointSelected()
{
if (ClosestClickedTimeSeriesName != null && ClosestClickedTimeSeriesName != "" && ClosestClickedTimeValue != null)
Expand All @@ -414,6 +494,61 @@ orderby sv.Time
}
}
}
public void SetNextSelectedSeries()
{
if (Series.Count > 0)
{
int selectedSeriesIndex = 0;
if (ClosestClickedTimeSeriesName != null && ClosestClickedTimeSeriesName != "")
{
selectedSeriesIndex = GetSeriesIndexByName(ClosestClickedTimeSeriesName);
if (selectedSeriesIndex == Series.Count - 1)
selectedSeriesIndex = 0;
else
selectedSeriesIndex++;
}
GraphSeries selectedSeries = Series[selectedSeriesIndex];
SetSelectedSeriesByName(selectedSeries.Name);

if (ClosestClickedTimeValue != null)
{
TimeValue tv = GetClosestPointForSeries(selectedSeries, ClosestClickedTimeValue);
if (tv != null)
{
ClosestClickedTimeValue = tv;
LastClickedLocation = tv;
ClosestPointSelectedChanged?.Invoke(ClosestClickedTimeSeriesName, tv);
}
}
}
}
public void SetPreviousSelectedSeries()
{
if (Series.Count > 0)
{
int selectedSeriesIndex = Series.Count - 1;
if (ClosestClickedTimeSeriesName != null && ClosestClickedTimeSeriesName != "")
{
selectedSeriesIndex = GetSeriesIndexByName(ClosestClickedTimeSeriesName);
if (selectedSeriesIndex <= 0)
selectedSeriesIndex = Series.Count - 1;
else
selectedSeriesIndex--;
}
GraphSeries selectedSeries = Series[selectedSeriesIndex];
SetSelectedSeriesByName(selectedSeries.Name);
if (ClosestClickedTimeValue != null)
{
TimeValue tv = GetClosestPointForSeries(selectedSeries, ClosestClickedTimeValue);
if (tv != null)
{
ClosestClickedTimeValue = tv;
LastClickedLocation = tv;
ClosestPointSelectedChanged?.Invoke(ClosestClickedTimeSeriesName, tv);
}
}
}
}
private void SetHightlightSeries()
{
if (HighlightClickedSeries)
Expand All @@ -428,6 +563,23 @@ private void SetHightlightSeries()
private TimeValue ConvertPointToTimeValue(int x, int y, bool forceInBounds = false)
{
TimeValue timeValue = null;

//if (ShowLegendText && y > (Height - legendHeight)) //legend area
//{
// foreach (var enabledSeries in (from serie in Series
// where serie.Enabled
// select serie))
// {
// if (enabledSeries.CurrentSeriesLabelLocation.X <= x && enabledSeries.CurrentSeriesLabelLocation.X + enabledSeries.CurrentSeriesLabelSize.Width > x)
// {
// if (enabledSeries.CurrentSeriesLabelLocation.Y <= y && enabledSeries.CurrentSeriesLabelLocation.Y + enabledSeries.CurrentSeriesLabelSize.Height > y)
// {
// System.Diagnostics.Trace.WriteLine(enabledSeries.Name);
// }
// }
// }
//}

if (forceInBounds)
{
if (x < LeftAxisMargin)
Expand Down Expand Up @@ -473,6 +625,7 @@ private TimeValue ConvertPointToTimeValue(int x, int y, bool forceInBounds = fal
}
}
}

return timeValue;
}
private Point ConvertTimeValueToPoint(TimeValue tv)
Expand Down Expand Up @@ -686,7 +839,6 @@ where serie.Enabled
}
if (enabledSeries.Selected)
{
//currentSeriesLabel = $">{currentSeriesLabel}<";
currentFont = new Font(GraphTextFont, FontStyle.Bold);
}
SizeF currentLabelSize = g.MeasureString(currentSeriesLabel, currentFont);
Expand All @@ -695,15 +847,22 @@ where serie.Enabled
if (legendXPos + currentLabelSize.Width + bufferBetweenLabels < this.Width)
{
g.DrawString(currentSeriesLabel, currentFont, drawBrush, legendXPos, legendYPos);
legendXPos += (int)currentLabelSize.Width + bufferBetweenLabels;
enabledSeries.CurrentSeriesLabelText = currentSeriesLabel;
enabledSeries.CurrentSeriesLabelLocation = new Point(legendXPos, legendYPos);
enabledSeries.CurrentSeriesLabelSize = currentLabelSize;

legendXPos += (int)currentLabelSize.Width + bufferBetweenLabels;
}
else
{
legendYPos += stdLineHeight;
legendXPos = bufferBetweenLabels;
g.DrawString(currentSeriesLabel, currentFont, drawBrush, legendXPos, legendYPos);
legendXPos += (int)currentLabelSize.Width + bufferBetweenLabels;
enabledSeries.CurrentSeriesLabelText = currentSeriesLabel;
enabledSeries.CurrentSeriesLabelLocation = new Point(legendXPos, legendYPos);
enabledSeries.CurrentSeriesLabelSize = currentLabelSize;

legendXPos += (int)currentLabelSize.Width + bufferBetweenLabels;
}
}
bottomMarginHeight += stdLineHeight;
Expand Down
2 changes: 1 addition & 1 deletion QuickMon5/QuickMonRemoteHostCMD/app.manifest
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<asmv1:assembly manifestVersion="1.0" xmlns="urn:schemas-microsoft-com:asm.v1" xmlns:asmv1="urn:schemas-microsoft-com:asm.v1" xmlns:asmv2="urn:schemas-microsoft-com:asm.v2" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<assemblyIdentity version="5.2.4.0059" name="QuickMonRemoteHostCMD.app"/>
<assemblyIdentity version="5.2.5.0060" name="QuickMonRemoteHostCMD.app"/>
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v2">
<security>
<requestedPrivileges xmlns="urn:schemas-microsoft-com:asm.v3">
Expand Down
2 changes: 1 addition & 1 deletion QuickMon5/QuickMonService/app.manifest
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<asmv1:assembly manifestVersion="1.0" xmlns="urn:schemas-microsoft-com:asm.v1" xmlns:asmv1="urn:schemas-microsoft-com:asm.v1" xmlns:asmv2="urn:schemas-microsoft-com:asm.v2" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<assemblyIdentity version="5.2.4.0059" name="QuickMonService.app"/>
<assemblyIdentity version="5.2.5.0060" name="QuickMonService.app"/>
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v2">
<security>
<requestedPrivileges xmlns="urn:schemas-microsoft-com:asm.v3">
Expand Down

0 comments on commit d80813b

Please sign in to comment.