Allowed Zoom feature to work with PavNum keys

PavNum keys (0 / + / -) will now work for the zoom feature
This commit is contained in:
Gurgarath 2022-07-08 09:21:21 +02:00 committed by GitHub
parent 91a73d37b4
commit fbbf32d92c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,4 +1,4 @@
#region License Information (GPL v3)
#region License Information (GPL v3)
/*
ShareX - A program that allows you to take screenshots and share any file type
@ -664,16 +664,20 @@ internal void RegionCaptureForm_KeyDown(object sender, KeyEventArgs e)
switch (e.KeyData)
{
case Keys.Control | Keys.Alt | Keys.D0:
case Keys.Control | Keys.Alt | Keys.NumPad0:
ZoomToFit();
break;
case Keys.Control | Keys.D0:
case Keys.Control | Keys.NumPad0:
ZoomFactor = 1;
CenterCanvas();
break;
case Keys.Control | Keys.Oemplus:
case Keys.Control | Keys.Add:
Zoom(true, false);
break;
case Keys.Control | Keys.OemMinus:
case Keys.Control | Keys.Subtract:
Zoom(false, false);
break;
}
@ -1695,4 +1699,4 @@ protected override void Dispose(bool disposing)
base.Dispose(disposing);
}
}
}
}