Minor refactoring

This commit is contained in:
Duc
2025-01-05 12:39:24 -07:00
parent 1bb3389ee6
commit d8d73197a9
2 changed files with 7 additions and 7 deletions

View File

@@ -112,7 +112,7 @@ namespace ProgramLib
_threadList.Last().Start(); _threadList.Last().Start();
} }
_threadList.Add(new PassthroughDataGuiUpdateThread()); _threadList.Add(new PassthroughDataUpdateThread());
_threadList.Last().Start(); _threadList.Last().Start();
_threadList.Add(new PowerSupplyUpdateThread()); _threadList.Add(new PowerSupplyUpdateThread());

View File

@@ -30,9 +30,9 @@ using System.Threading.Tasks;
namespace ProgramLib namespace ProgramLib
{ {
/// <summary> /// <summary>
/// Class to spawn thread to update passthrough data on GUI /// Class to spawn thread to update passthrough data
/// </summary> /// </summary>
internal class PassthroughDataGuiUpdateThread : BasicThread internal class PassthroughDataUpdateThread : BasicThread
{ {
private enum Events private enum Events
{ {
@@ -52,7 +52,7 @@ namespace ProgramLib
/// <summary> /// <summary>
/// Constructor /// Constructor
/// </summary> /// </summary>
public PassthroughDataGuiUpdateThread() public PassthroughDataUpdateThread()
{ {
_logger = LogManager.GetCurrentClassLogger(); _logger = LogManager.GetCurrentClassLogger();
@@ -66,7 +66,7 @@ namespace ProgramLib
}); });
} }
~PassthroughDataGuiUpdateThread() ~PassthroughDataUpdateThread()
{ {
_logger?.Debug($"Entering {this.GetType().Name}::{System.Reflection.MethodBase.GetCurrentMethod().Name}() ..."); _logger?.Debug($"Entering {this.GetType().Name}::{System.Reflection.MethodBase.GetCurrentMethod().Name}() ...");
} }
@@ -95,7 +95,7 @@ namespace ProgramLib
if (id == Events.UUT_POWER_ON) if (id == Events.UUT_POWER_ON)
{ {
UpdatePassthroughDataGui(); UpdatePassthroughData();
} }
else else
break; break;
@@ -115,7 +115,7 @@ namespace ProgramLib
/// </summary> /// </summary>
/// <param name=""></param> /// <param name=""></param>
/// <returns></returns> /// <returns></returns>
private void UpdatePassthroughDataGui() private void UpdatePassthroughData()
{ {
int pollRateMs = 1000; int pollRateMs = 1000;
_logger?.Debug($"{this.GetType().Name}::{System.Reflection.MethodBase.GetCurrentMethod().Name}() is running..."); _logger?.Debug($"{this.GetType().Name}::{System.Reflection.MethodBase.GetCurrentMethod().Name}() is running...");