Skip to content

Commit

Permalink
Add a deadzone to the zoom slider (see ngld#152)
Browse files Browse the repository at this point in the history
  • Loading branch information
ngld committed Dec 10, 2020
1 parent 661e4eb commit d5403e1
Show file tree
Hide file tree
Showing 2 changed files with 78 additions and 72 deletions.
6 changes: 6 additions & 0 deletions OverlayPlugin.Core/Overlays/MiniParseConfigPanel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -250,6 +250,12 @@ private void checkLogConsoleMessages_CheckedChanged(object sender, EventArgs e)

private void tbZoom_ValueChanged(object sender, EventArgs e)
{
if (this.config.Zoom == 1 && Math.Abs(this.config.Zoom - this.tbZoom.Value) < 10)
{
// Don't change the zoom level if we don't want any zoom (see #152 for details).
return;
}

this.config.Zoom = this.tbZoom.Value;
}

Expand Down
Loading

0 comments on commit d5403e1

Please sign in to comment.