summaryrefslogtreecommitdiff
path: root/grapher/Models/Fields
diff options
context:
space:
mode:
authorJacob Palecki <[email protected]>2020-08-12 20:39:53 -0700
committerJacob Palecki <[email protected]>2020-08-12 20:39:53 -0700
commit30e1391b224ae028f4476e06a07415a0285ac6c9 (patch)
treea70694de4ca5e8e9f947ce6a1355c7a134d491b8 /grapher/Models/Fields
parentFactor accel calculations into calculation classes (diff)
downloadrawaccel-30e1391b224ae028f4476e06a07415a0285ac6c9.tar.xz
rawaccel-30e1391b224ae028f4476e06a07415a0285ac6c9.zip
Almost working
Diffstat (limited to 'grapher/Models/Fields')
-rw-r--r--grapher/Models/Fields/FieldXY.cs7
1 files changed, 6 insertions, 1 deletions
diff --git a/grapher/Models/Fields/FieldXY.cs b/grapher/Models/Fields/FieldXY.cs
index 87e0b9c..609af9d 100644
--- a/grapher/Models/Fields/FieldXY.cs
+++ b/grapher/Models/Fields/FieldXY.cs
@@ -13,13 +13,14 @@ namespace grapher
public const string ShortenedFormatString = "0.###";
- public FieldXY(TextBox xBox, TextBox yBox, CheckBox lockCheckBox, Form containingForm, double defaultData)
+ public FieldXY(TextBox xBox, TextBox yBox, CheckBox lockCheckBox, Form containingForm, double defaultData, AccelCharts accelCharts)
{
XField = new Field(xBox, containingForm, defaultData);
YField = new Field(yBox, containingForm, defaultData);
YField.FormatString = ShortenedFormatString;
LockCheckBox = lockCheckBox;
LockCheckBox.CheckedChanged += new System.EventHandler(CheckChanged);
+ AccelCharts = accelCharts;
XField.Box.Width = (YField.Box.Left + YField.Box.Width - XField.Box.Left - DefaultSeparation) / 2;
YField.Box.Width = XField.Box.Width;
@@ -58,6 +59,8 @@ namespace grapher
public Field YField { get; }
+ private AccelCharts AccelCharts { get; }
+
private bool Combined { get; set; }
private int DefaultWidthX { get; }
@@ -76,6 +79,8 @@ namespace grapher
{
SetSeparate();
}
+
+ AccelCharts.RefreshXY();
}
public void SetCombined()