summaryrefslogtreecommitdiff
path: root/grapher/Models/Serialized/GUISettings.cs
diff options
context:
space:
mode:
authora1xd <[email protected]>2020-10-08 02:07:56 -0400
committera1xd <[email protected]>2020-10-08 02:07:56 -0400
commit2be0106211cb4ce30036fc0c8e84ae70dff68c87 (patch)
treed36296ff0402c014d355b7fb1b8e7cc4c11fc3f4 /grapher/Models/Serialized/GUISettings.cs
parentease requirements for loading driver settings (diff)
downloadrawaccel-2be0106211cb4ce30036fc0c8e84ae70dff68c87.tar.xz
rawaccel-2be0106211cb4ce30036fc0c8e84ae70dff68c87.zip
add toggle button + save gui settings on close
remove option to disable write on startup
Diffstat (limited to 'grapher/Models/Serialized/GUISettings.cs')
-rw-r--r--grapher/Models/Serialized/GUISettings.cs27
1 files changed, 15 insertions, 12 deletions
diff --git a/grapher/Models/Serialized/GUISettings.cs b/grapher/Models/Serialized/GUISettings.cs
index 84e681b..f9e5755 100644
--- a/grapher/Models/Serialized/GUISettings.cs
+++ b/grapher/Models/Serialized/GUISettings.cs
@@ -10,32 +10,35 @@ namespace grapher.Models.Serialized
public GUISettings() {}
- public GUISettings(bool autoWrite, int dpi, int pollRate)
- {
- AutoWriteToDriverOnStartup = autoWrite;
- DPI = dpi;
- PollRate = pollRate;
- }
-
#endregion Constructors
#region Properties
- [JsonProperty(Order = 1)]
- public bool AutoWriteToDriverOnStartup { get; set; }
- [JsonProperty(Order = 2)]
+ [JsonProperty(Order = 1)]
public int DPI { get; set; }
- [JsonProperty(Order = 3)]
+ [JsonProperty(Order = 2)]
public int PollRate { get; set; }
- [JsonProperty(Order = 4)]
+ [JsonProperty(Order = 3)]
public bool ShowLastMouseMove { get; set; }
[JsonProperty(Order = 4)]
public bool ShowVelocityAndGain { get; set; }
#endregion Properties
+
+ #region Methods
+
+ public bool ValueEquals(GUISettings other)
+ {
+ return DPI == other.DPI &&
+ PollRate == other.PollRate &&
+ ShowLastMouseMove == other.ShowLastMouseMove &&
+ ShowVelocityAndGain == other.ShowVelocityAndGain;
+ }
+
+ #endregion Methods
}
}