From f5fccc0ca5b38e7b933f9306271b8c60ceb46c12 Mon Sep 17 00:00:00 2001 From: Callum McIntyre Date: Thu, 10 Nov 2016 11:41:30 +0000 Subject: [PATCH] [CA-228054] Performance graph datasources aren't sorted naturally Replace the string comparison used when sorting columns of the datasources list table with a natural compare, which sorts these cases correctly. --- XenAdmin/Dialogs/GraphDetailsDialog.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/XenAdmin/Dialogs/GraphDetailsDialog.cs b/XenAdmin/Dialogs/GraphDetailsDialog.cs index 00a139e7c..e8f29284b 100644 --- a/XenAdmin/Dialogs/GraphDetailsDialog.cs +++ b/XenAdmin/Dialogs/GraphDetailsDialog.cs @@ -37,6 +37,7 @@ using System.Linq; using System.Windows.Forms; using XenAdmin.Actions; using XenAdmin.Controls.CustomDataGraph; +using XenAdmin.Core; namespace XenAdmin.Dialogs @@ -266,7 +267,7 @@ namespace XenAdmin.Dialogs } else { - result = string.Compare(row1.Cells[columnIndex].Value.ToString(), + result = StringUtility.NaturalCompare(row1.Cells[columnIndex].Value.ToString(), row2.Cells[columnIndex].Value.ToString()); }