summaryrefslogtreecommitdiff
path: root/grapher/Models/AccelGUI.cs
diff options
context:
space:
mode:
authorJacob Palecki <[email protected]>2020-09-03 20:10:43 -0700
committerJacob Palecki <[email protected]>2020-09-03 20:10:43 -0700
commit2fbc4b3d504962c2462d7aec98f5f389e5333164 (patch)
tree2230e353985551a21a25b09bfacb89467b52d165 /grapher/Models/AccelGUI.cs
parentRefactor for nice gain offset (diff)
downloadrawaccel-2fbc4b3d504962c2462d7aec98f5f389e5333164.tar.xz
rawaccel-2fbc4b3d504962c2462d7aec98f5f389e5333164.zip
Add offset options to GUI, make gain options default
Diffstat (limited to 'grapher/Models/AccelGUI.cs')
-rw-r--r--grapher/Models/AccelGUI.cs11
1 files changed, 6 insertions, 5 deletions
diff --git a/grapher/Models/AccelGUI.cs b/grapher/Models/AccelGUI.cs
index 1657074..a7d5d49 100644
--- a/grapher/Models/AccelGUI.cs
+++ b/grapher/Models/AccelGUI.cs
@@ -1,5 +1,6 @@
using grapher.Models.Calculations;
using grapher.Models.Mouse;
+using grapher.Models.Options;
using grapher.Models.Serialized;
using System;
using System.CodeDom;
@@ -28,7 +29,7 @@ namespace grapher
Option rotation,
OptionXY weight,
CapOptions cap,
- Option offset,
+ OffsetOptions offset,
Option acceleration,
Option limtOrExp,
Option midpoint,
@@ -82,7 +83,7 @@ namespace grapher
public CapOptions Cap { get; }
- public Option Offset { get; }
+ public OffsetOptions Offset { get; }
public Option Acceleration { get; }
@@ -119,8 +120,8 @@ namespace grapher
{
x = new AccelArgs
{
- offset = Offset.Field.Data,
- legacy_offset = 0,
+ offset = Offset.Offset,
+ legacy_offset = Offset.LegacyOffset,
weight = Weight.Fields.X,
gainCap = Cap.VelocityGainCap,
scaleCap = Cap.SensitivityCapX,
@@ -163,7 +164,7 @@ namespace grapher
Sensitivity.SetActiveValues(settings.sensitivity.x, settings.sensitivity.y);
Rotation.SetActiveValue(settings.rotation);
AccelerationOptions.SetActiveValue((int)settings.modes.x);
- Offset.SetActiveValue(settings.args.x.offset);
+ Offset.SetActiveValue(settings.args.x.offset, settings.args.y.offset);
Weight.SetActiveValues(settings.args.x.weight, settings.args.x.weight);
Acceleration.SetActiveValue(settings.args.x.accel); // rate, powerscale
LimitOrExponent.SetActiveValue(settings.args.x.limit); //exp, powerexp