Skip to content

Commit

Permalink
fix #1072
Browse files Browse the repository at this point in the history
thanks for helping, .net
  • Loading branch information
vadosnaprimer committed Jan 2, 2018
1 parent 8e9b5af commit 7896664
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions BizHawk.Client.EmuHawk/tools/TAStudio/GreenzoneSettings.cs
Expand Up @@ -41,8 +41,10 @@ private void StateHistorySettings_Load(object sender, EventArgs e)

MemStateGapDividerNumeric.Maximum = Statable.SaveStateBinary().Length / 1024 / 2 + 1;
MemStateGapDividerNumeric.Minimum = Statable.SaveStateBinary().Length / 1024 / 16;
MemStateGapDividerNumeric.Value = _settings.MemStateGapDivider < MemStateGapDividerNumeric.Minimum ?
MemStateGapDividerNumeric.Minimum : _settings.MemStateGapDivider;

// props to .net for this amazing Clamp() implementation
MemStateGapDividerNumeric.Value = Math.Min(Math.Max(_settings.MemStateGapDivider,
MemStateGapDividerNumeric.Minimum), MemStateGapDividerNumeric.Maximum);

FileStateGapNumeric.Value = _settings.FileStateGap;
SavestateSizeLabel.Text = Math.Round(_stateSizeMb, 2).ToString() + " MB";
Expand Down

0 comments on commit 7896664

Please sign in to comment.