Skip to content

Commit

Permalink
Fix: Stricter validation for gamma value & attempt to fix lack of ent…
Browse files Browse the repository at this point in the history
…ers in CI build
  • Loading branch information
Piotrekol committed Mar 14, 2021
1 parent 903a2a8 commit 320b907
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
3 changes: 2 additions & 1 deletion plugins/Gamma/GammaSettings.cs
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,10 @@ private void DataGridViewOnDataBindingComplete(object sender, DataGridViewBindin
{
Validate("MinAr", 0, 15);
Validate("MaxAr", 0, 15);
Validate("Gamma", 0.2, 4.5);
Validate("Gamma", 0.228, 4.46);
OnSettingUpdated?.Invoke(this, EventArgs.Empty);
}

private void Validate(string columnName, double min, double max)
{
for (int i = 0; i < dataGridView.Rows.Count; i++)
Expand Down
10 changes: 5 additions & 5 deletions plugins/Gamma/GammaSettings.resx
Original file line number Diff line number Diff line change
Expand Up @@ -58,10 +58,10 @@
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<data name="textBox1.Text" xml:space="preserve">
<value>MinAr - minimum AR to trigger gamma change (0,01-15,00)
MaxAr - maximum AR to trigger gamma change (0,01-15,00)
Gamma - gamma value to apply (0,228 ~ 4,46)
0 being unusable bright and 5 everything black
Gamma activates only when playing and both MinAr and MaxAr conditions are satisfied</value>
<value>MinAr - minimum AR to trigger gamma change (0,01-15,00)
MaxAr - maximum AR to trigger gamma change (0,01-15,00)
Gamma - gamma value to apply (0,228 ~ 4,46)
0,228 being really bright and 5 really dark.
Gamma activates only when playing and both MinAr and MaxAr conditions are satisfied </value>
</data>
</root>

0 comments on commit 320b907

Please sign in to comment.