Browse Source

Fix Prev Block Times display

Stuart Johnson 1 year ago
parent
commit
19ab6f4ae0
2 changed files with 18 additions and 8 deletions
  1. 17 7
      .vs/TFA-Bot/xs/UserPrefs.xml
  2. 1 1
      TFA-Bot/DataClasses/clsNetwork.cs

+ 17 - 7
.vs/TFA-Bot/xs/UserPrefs.xml

@@ -3,27 +3,37 @@
   <MonoDevelop.Ide.Workbench ActiveDocument="TFA-Bot Status">
     <Files>
       <File FileName="TFA-Bot/Spreadsheet/clsSpreadsheetReader.cs" Line="125" Column="1" />
-      <File FileName="TFA-Bot/DiscordBot/Commands/clsHelp.cs" Line="24" Column="54" />
-      <File FileName="TFA-Bot/DiscordBot/Commands/clsNetworks.cs" Line="34" Column="34" />
-      <File FileName="TFA-Bot/DataClasses/clsNetwork.cs" Line="24" Column="21" />
+      <File FileName="TFA-Bot/DiscordBot/Commands/clsHelp.cs" Line="44" Column="1" />
+      <File FileName="TFA-Bot/DiscordBot/Commands/clsNetworks.cs" Line="32" Column="45" />
+      <File FileName="TFA-Bot/DataClasses/clsNetwork.cs" Line="56" Column="13" />
       <File FileName="TFA-Bot/clsExtenstions.cs" Line="57" Column="30" />
       <File FileName="TFA-Bot/DiscordBot/Commands/clsListNodes.cs" Line="21" Column="65" />
-      <File FileName="TFA-Bot/Program.cs" Line="162" Column="84" />
-      <File FileName="TFA-Bot/DataClasses/clsNodeGroup.cs" Line="73" Column="30" />
+      <File FileName="TFA-Bot/Program.cs" Line="34" Column="96" />
+      <File FileName="TFA-Bot/DataClasses/clsNodeGroup.cs" Line="26" Column="29" />
       <File FileName="TFA-Bot/DataClasses/clsNode.cs" Line="97" Column="62" />
       <File FileName="TFA-Bot/DiscordBot/clsBotClient.cs" Line="169" Column="84" />
       <File FileName="TFA-Bot/clsEmail.cs" Line="96" Column="14" />
       <File FileName="TFA-Bot/clsAlarm.cs" Line="107" Column="34" />
       <File FileName="TFA-Bot/DiscordBot/Commands/clsDiscord.cs" Line="32" Column="13" />
       <File FileName="TFA-Bot/DiscordBot/Commands/clsGoodnight.cs" Line="31" Column="1" />
-      <File FileName="TFA-Bot/DiscordBot/Commands/clsEmail.cs" Line="26" Column="55" />
+      <File FileName="TFA-Bot/DiscordBot/Commands/clsEmail.cs" Line="30" Column="1" />
+      <File FileName="TFA-Bot/DiscordBot/Commands/clsAlarm.cs" Line="1" Column="1" />
+      <File FileName="TFA-Bot/DiscordBot/Commands/IBotCommand.cs" Line="21" Column="1" />
+      <File FileName="TFA-Bot/DiscordBot/clsCommands.cs" Line="40" Column="60" />
+      <File FileName="TFA-Bot/clsColumnDisplay.cs" Line="20" Column="50" />
+      <File FileName="TFA-Bot/Spreadsheet/clsSpreadsheet.cs" Line="26" Column="58" />
+      <File FileName="TFA-Bot/Spreadsheet/ASheetColumnHeader.cs" Line="1" Column="1" />
+      <File FileName="TFA-Bot/Spreadsheet/ISpreadsheet.cs" Line="1" Column="1" />
       <File FileName="TFA-Bot Status" />
     </Files>
     <Pads>
       <Pad Id="ProjectPad">
         <State name="__root__">
           <Node name="TFA-Bot" expanded="True">
-            <Node name="TFA-Bot" expanded="True" selected="True">
+            <Node name="TFA-Bot" expanded="True">
+              <Node name="DataClasses" expanded="True">
+                <Node name="clsNetwork.cs" selected="True" />
+              </Node>
               <Node name="DiscordBot" expanded="True">
                 <Node name="Commands" expanded="True" />
               </Node>

+ 1 - 1
TFA-Bot/DataClasses/clsNetwork.cs

@@ -132,7 +132,7 @@ namespace TFABot
                 columnDisplay.AppendCol(NextHeight.HasValue ? $"{(NextHeight.Value - DateTime.UtcNow).ToMSDisplay()}":"n/a");
                 
                 var sb = new StringBuilder();
-                foreach (var bt in AverageBlocktime.GetValues().Take(3).Reverse())
+                foreach (var bt in AverageBlocktime.GetValues().Reverse().Take(3))
                 {
                     if (sb.Length>0) sb.Append("<");
                     sb.Append($"[{new TimeSpan(0,0,bt).ToMSDisplay()}]");