From 61776821763e2bc4e7a12b1fac0da2b2df90b009 Mon Sep 17 00:00:00 2001 From: ncguilbeault Date: Mon, 3 Jun 2024 10:25:35 +0100 Subject: [PATCH] Updated internal properties to private --- .../KinematicStateVisualizer.cs | 20 +++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/src/Bonsai.ML.Visualizers/KinematicStateVisualizer.cs b/src/Bonsai.ML.Visualizers/KinematicStateVisualizer.cs index 7ea4e963..9a5f5736 100644 --- a/src/Bonsai.ML.Visualizers/KinematicStateVisualizer.cs +++ b/src/Bonsai.ML.Visualizers/KinematicStateVisualizer.cs @@ -19,14 +19,14 @@ namespace Bonsai.ML.Visualizers /// public class KinematicStateVisualizer : MashupVisualizer { - internal int RowCount { get; set; } = 3; - internal int ColumnCount { get; set; } = 2; internal List ComponentVisualizers { get; private set; } = new(); private TableLayoutPanel container; private int updateFrequency = 1000 / 50; private bool resetAxes = true; + private int rowCount = 3; + private int columnCount = 2; - internal string[] Labels = new string[] { + private string[] labels = new string[] { "Position X", "Position Y", "Velocity X", @@ -40,27 +40,27 @@ public override void Load(IServiceProvider provider) { container = new TableLayoutPanel { - ColumnCount = ColumnCount, - RowCount = RowCount, + ColumnCount = columnCount, + RowCount = rowCount, Dock = DockStyle.Fill }; for (int i = 0; i < container.RowCount; i++) { - container.RowStyles.Add(new RowStyle(SizeType.Percent, 100f / RowCount)); + container.RowStyles.Add(new RowStyle(SizeType.Percent, 100f / rowCount)); } for (int i = 0; i < container.ColumnCount; i++) { - container.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100f / ColumnCount)); + container.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100f / columnCount)); } - for (int i = 0 ; i < RowCount; i++) + for (int i = 0 ; i < rowCount; i++) { - for (int j = 0; j < ColumnCount; j++) + for (int j = 0; j < columnCount; j++) { var StateComponentVisualizer = new StateComponentVisualizer() { - Label = Labels[i * ColumnCount + j] + Label = labels[i * columnCount + j] }; StateComponentVisualizer.Load(provider); container.Controls.Add(StateComponentVisualizer.Plot, j, i);